respondsTo: bug

Tom Phoenix rootbeer at redcat.com
Tue Dec 18 19:14:59 UTC 2007


On 12/18/07, Doug Edmunds <dae at douglasedmunds.com> wrote:

> (3 @ 4) respondsTo: #<=.  "Squeak reports this as false"

Could you double-check that, please? Maybe it's different in your
release of Squeak, but I get a true value.

> Trying other methods for Point, I get many similar 'false' results when
> sending 'respondsTo:' to Point (but I also get many correct results).
>
> ie.
>
> Point respondsTo: #abs.  "false"

You're sending that message to Point, a class, rather than to an
instance of Point. The class doesn't respond to abs, but an instance
should.

  (3 at 2.5) respondsTo: #abs.   "true"
  (3 at 2.5) respondsTo: #basicNew.    "false"

Hope this helps!

--Tom Phoenix



More information about the Squeak-dev mailing list