Next Tricks of the Wizards 74

Missing tie Methods

        sub unimplemented { }
        # Load `Carp' when needed
        sub forbidden { 
          require Carp;
          Carp::croak("Operation not permitted on tied hash");
        }

        for $name (qw(STORE DELETE CLEAR FIRSTKEY NEXTKEY)) {        
          *{$name} = \&forbidden;
        }


Next Copyright © 2003 M. J. Dominus