[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index][Thread Index][Top&Search][Original]

Re: Class::Fields, a base/fields.pm rewrite



On Sun, Jan 09, 2000 at 01:15:08AM -0500, Michael G Schwern wrote:
> >   sub has_fields { *{ ${ shift() . '::' }{FIELDS} || \*has_fields }{HASH} }
> > 
> > 1/2 ;-)
> 
> No, I believe it has to be 'and'.  The statement is actually written
> in a confusing manner.  I'm trying to accomplish this:
> 
>         if( $fglob = ${"$class\::"}{"FIELDS"} ) {
>                 return (*$fglob{HASH}) ? 1 : 0;
>         }
>         else {
>                 return 0;
>         }

This is what my version is doing (assuming you do not have %has_fields
in this package).

Ilya


References to:
Michael G Schwern <schwern@pobox.com>
Ilya Zakharevich <ilya@math.ohio-state.edu>
Michael G Schwern <schwern@pobox.com>
Ilya Zakharevich <ilya@math.ohio-state.edu>
Michael G Schwern <schwern@pobox.com>

[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index][Thread Index][Top&Search][Original]