4 ms·
The usual phrase I've seen to describe this is "passes references by value". And it's the norm in almost all popular OOP languages since the mid-90s.
by barrkel 14y ago
The usual phrase I've seen to describe this is "passes references by value". And it's the norm in almost all popular OOP languages since the mid-90s.
- sirclueless 14y agoI like to think of this as "call-by-name". That's because every name in python is actually a lookup in a dictionary mapping strings to values. This is different from languages like C# and Java where some things such as class and function references can actually be thought of as "values". In python, everything that isn't a keyword or a literal is a name, thinking otherwise leads to gotchas.
- pdw 14y agoThe term call-by-name already exists and means something entirely different. It will blow your mind. http://www.cs.sfu.ca/~cameron/Teaching/383/PassByName.html http://www.cs.sfu.ca/~cameron/Teaching/383/PassByName.html