On Thu, 30 Jun 2005 at 16:42 +0200, Rafael Garcia-Suarez <[EMAIL PROTECTED]:

From: Rafael Garcia-Suarez <[EMAIL PROTECTED]>
If the line deparses the same, than why was the
error message only issued for the "push @ISA, __PACKAGE__" line?

Because __PACKAGE__ is a constant. Use Devel::Peek to peek at it.

Thanks for the pointer to Devel::Peek, I don't use it enough...

$ perl -e 'use Devel::Peek; Dump( __PACKAGE__);'
SV = PV(0x8153890) at 0x8164118
  REFCNT = 1
  FLAGS = (POK,FAKE,READONLY,pPOK)
  PV = 0x815be8c "main"
  CUR = 4
  LEN = 0

$ perl -e 'use Devel::Peek; Dump( 'main' );'
SV = PV(0x8153890) at 0x8164110
  REFCNT = 1
  FLAGS = (POK,READONLY,pPOK)
  PV = 0x81638e8 "main"\0
  CUR = 4
  LEN = 8

I guess __PACKAGE__ is one of those constants that  O::Deparse
can't regenerate the correct source for, right?  Seems like
they are both READONLY but __PACKAGE__ is "FAKE".

Reply via email to