in reply to Re: Abusing attributes (possible perl bug?)
in thread Abusing attributes (possible perl bug?)

Well, then I guess it's a bug since then it should probably emit a parser error.

But note that this works:
sub CLASS_DEFINITION: ATTRIBUTES: PRIVATE: pvt_at1 pvt_at2 pvt_at3 PROTECTED: ptc_at1 ptc_at2 ptc_at3 PUBLIC: pub_at1 pub_at2 pub_at3 METHODS: PRIVATE: pvt_mt1 pvt_mt2 pvt_mt3 PROTECTED: ptc_mt1 ptc_mt2 ptc_mt3 PUBLIC: pub_mt1 pub_mt2 pub_mt3 ;

code edited: missing ':'
It gets interpreted to a lot of attributes. And it spans multiple lines.

Just a side note, but I actually wrote code that handles this sort of attribute depiction and creates the accessors methods and such.

Somehow, yesterday this all seemed like a very good idea but today it seems like a brain-dead way to do things.
But I'm still curious about all of this. Should I report it as a bug or something like that?


acid06
perl -e "print pack('h*', 16369646), scalar reverse $="

Replies are listed 'Best First'.
Re^3: Abusing attributes (possible perl bug?)
by salva (Canon) on Feb 08, 2006 at 14:31 UTC
    the bug seems to affect only expressions where opening {, [ and { do not match clossing }, ] and ) on every line.

    and yes, you should report it.

      and yes, you should report it.
      Note, however, that problem is inherent to the perl parser, and not specific to the Attribute::Handlers module. So please report it via perlbug.

      Damian