From: Clifford Heath Date: 2007-09-20T06:55:05+09:00 Subject: Re: capturing access to array elements mortee wrote: >> My chattr gem does this so it can do type-checking. It's small, install >> it and have a read. > It looks great, but it doesn't seem to be applicable in my case. I have > to deal with arrays already created by a library function and returned > to me, so I can't prescribe their actual class. No, but you can re-open the class that they are of, and apply all the methods from chattr, which replicates exactly the behaviour of the standard Array class, so you know you haven't broken anything by interjecting.