On Mon, Dec 17, 2007 at 10:06:42AM -0600, Andy Lester wrote: > Andy: My consting has run into its greatest challenge yet. > Andy: Making self args to PMCs consts where appropriate. > Andy: <jarring chord> > Andy: INTVAL such_and_such_elements( PMC *self ); > Andy: Tell me that *self shouldn't be const. > Andy: Go on, tell me. > Andy: You can't. > > particle: of course i can't > particle: in accessors, self should be constant
The equivalent would break in Perl 5, where the "objects" can change internal private state as a side effect of being read. For example, conversions are cached. Nicholas Clark