From: Austin Ziegler Date: 2002-11-04T05:00:22+09:00 Subject: Re: Thoughts on Ruby On Mon, 4 Nov 2002 04:39:35 +0900, Albert Wagner wrote: > On Saturday 02 November 2002 11:56 pm, Austin Ziegler wrote: >> On Sun, 3 Nov 2002 10:57:29 +0900, Enric Lafont wrote: >>> Why does common operators like "=" , "and", " .." , "or" etc ... >>> can not be overloaded or redefined ?, maybe the complexity of >>> the Ruby parser comes from the fact that everything is ALMOST an >>> object or a method. >> I don't actually see this (that everything is "almost" an >> object). > I read this differently. Certain peculiarities in the english > syntax led me to suspect english-as-second language. I assumed, > rightly or wrongly, that Enric meant that: ALMOST everything is an > object or a method. I tried to read beyond the ESL. I still don't see that "almost everything is an object or method". To me, everything in Ruby *is* an object, and with the exception of boolean combinations and keywords (and, or, etc.), everything else is a method -- even if it doesn't have to be written that way. (I agree that from a SmallTalk perspective that the fact that loops & such aren't messages does appear weird.) >>> Why is not "=" a method? > Again, I think a misunderstanding. > > assignment comparator > Smalltalk := = > Ruby = == I'm not sure. '=' isn't a method, and it doesn't make sense to be a method. '==' *is* a method and it's redefinable. -austin -- Austin Ziegler, austin@halostatue.ca on 2002.11.03 at 14.45.48