insteadof operator

monolithed monolithed at gmail.com
Sat Jul 11 13:40:53 UTC 2015


There's an an equivalent in C++:


```c++
#include <iostream>

static int foo = 1;

int bar (const int &foo) {
::foo = 2;

return foo;
}

int main () {
std::cout << foo << ',' << bar(1) << std::endl; // 2,1
 return 0;
}
```

`::` is more reasonable for me
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/es-discuss/attachments/20150711/ba30426d/attachment.html>


More information about the es-discuss mailing list