Guest User

Untitled

a guest
Jun 23rd, 2018
78
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.32 KB | None | 0 0
  1. inline int ProcessByValue(int i)
  2. {
  3. // process i somehow
  4. }
  5.  
  6. inline int ProcessByReference(const int& i)
  7. {
  8. // process i somehow
  9. }
  10.  
  11. int two = plus1( 1 ); // compile error if plus1 is declared as "int plus1( int& )"
  12.  
  13. double y = sqrt( 1.1 * 2 ); // compile error if sqrt is declared as "double sqrt( const double& )"
Add Comment
Please, Sign In to add comment