Forum: Ruby Redefining #equal? for a really thin wrapper?

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
Accaf690f3d97aab6e6e02adac8150be?d=identicon&s=25 Student Jr (student)
on 2014-03-27 03:29
I'm looking into DCI (Data, Context Interaction --  I'm unhappy with the
implementation I'm seeing, so I'm looking at rolling my own.  I've
decided that I want to use wrapper objects--really, really thin wrapper
objects.  In particular, my plan is to redefine the equality operators,
like so:

Of course, these things don't inherit from Object or Kernel.  I don't
want to go into the debate about how to implement DCI here.  My question
is simply whether or not anything in the ruby core breaks if I redefine
#equal? and #__object_id__.
This topic is locked and can not be replied to.