[C++-sig] wrapping operator=

Stefan Seefeld seefeld at sympatico.ca
Mon May 25 19:58:17 CEST 2009

Hans Roessler wrote:
> But still I am looking for a way to allow the simple "data=42." syntax with the same result, because it would best copy the C++ syntax.
Would it, really ? I think it would be extremely confusing, if it would 
work. But it doesn't. "a = b" doesn't assign to an object, but to a 
variable. Variables in Python have reference semantics, so you'd simply 
reassign the name to a different object.



      ...ich hab' noch einen Koffer in Berlin...

More information about the Cplusplus-sig mailing list