On Wed, Apr 18, 2001 at 01:40:53PM +0200, Martin von Loewis wrote: | Luke <floods at netplus.net> writes: | > | > Why do you always have to access class data members as self.* What a | > pain in the ass, and anti-OO. | | I disagree. In Smalltalk, which is one of the oldest OO languages, the | object being dealt with is always referred-to as "self". Even in a | natural language, the actor always refers to the subject of an action, | even if the subject is the actor ("I understand this", not "Understand | this"). Only in English. In other languages (Spanish comes to mind, I don't really know any others but AFAIK all Romance languages are identical in this regard) the verb changes to indicate the subject. I belive this comes from the time (~1044 AD) when the Norman French invaded England. At that time the smart (rich) people spoke French while the uneducated (poor) people spoke English. As a result of the English speakers being uneducated and spread out the language evolved to become closer to slang and varied from region to region. Sometime after the french were no longer ruling the writers of the time began to re-standardize the language. I think that the functions should be named differently to indicate the subject for each possible use of the function so the compiler/interpreter will automatically know exactly which subject is "self"/"this" <wink>. -D
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4