Am 02.10.2008 um 10:26 schrieb Randal L. Schwartz:

But the debugger doesn't have any special privileges, and it can clearly access every inst var, regardless of whether accessors exist or not, through
the magic of #instVarAt: and friends.

There is no magic in #instVarAt:. It exists merely for helping debugging.

So code would merely have to execute the equivalent of the primitives behind #instVarAt: and #instVarAt:put:, and no amount of wrapper class would help.


That is not correct. There are no primitives that modify/access *other* objects. That would break encapsulation.

All you need to do to prevent the debugger from accessing instance variables is overwriting the methods the debugger invokes.

- Bert -

_______________________________________________
Beginners mailing list
Beginners@lists.squeakfoundation.org
http://lists.squeakfoundation.org/mailman/listinfo/beginners

Reply via email to