I've been thinking about adding a reference type for a while now, though not in the 1.1 time-frame. My use case has been providing support for data binding and other such goodies – not directly in JRuby, probably as a gem, but with the underlying support/framework provided by JRuby. I've also been thinking about (possibly as an alternative) providing an event listener mechanism, so that code could register/listen for property events, including (but not necessarily limited to) ivar/cvar/constant events.
There will be some performance considerations with either of these approaches, but I think the impact can be minimized if done correctly.
BTW, I've also been thinking about using a reference type as part of an alternative method caching strategy, but I haven't had time to fully work this out. (Basically, a CacheSite [such as InlineCachingCallSite] would obtain a MethodReference, which would remain valid for all time [though the (volatile) referenced method might change]. The MethodReferences would be cached at the metaclasses where the methods were referenced. An event listener mechanism would be used to keep them up to date. As I said, not fully worked out.)
In general, I think we should consider building an event mechanism into JRuby 2 that will support listening for a number of internal event types. We should also consider exposing this mechanism through Ruby, via a gem or other optional module. Among other things, we could provide a superior (but non-standard and therefore necessarily optional) alternative to the rename-override-call_renamed approach of hooking events like :method_added.
Some internal code could also be refactored to use the new event mechanism.
Do we expose these now as attrs? Exposing as an instance var could be very tricky, since it would require hooking into (and potentially slowing down) hash-based lookup of non-field ivars.