On Thu, Feb 27, 2003 at 03:01:40AM -0800, schwern@pobox.com wrote: > On Thu, Feb 27, 2003 at 01:18:45AM -0500, Benjamin Goldberg wrote: > > (This is the second time in two weeks that I've seen someone write code > > with the believe that coderefs are the only type of ref which can go > > into @INC ... I would love to know where this misconception came from.) > > Its not widely known that you can even put code refs into @INC and IIRC > none of this was documented prior to 5.8.0. So its not so hard a stretch > that people might not know all the details. It's usually referred to as coderef-@INC, even though there are other things that can be put there. 5.6.1 doesn't "support" anything (it's undocumented) but actually you can only use array refs and code refs there. Calling the INC method on blessed references only came in somewhere in the 5.7 series. Possibly the logic of the tests in 5.8 is wrong - if you put an object in that is a blessed array, it gets treated as "array" (ie fetch element 0 and use it subsequently; pass the whole array in as arguments) rather than "object" I don't think that this ordering is documented. Nicholas ClarkThread Previous | Thread Next