while () { # get a line of POD if (/^=item\s+(LDAP_\S+)\s+\((.*)\)/) {# look for a POD line of =item LDAP_ () $const{$name} = sub () { $value }; # set the constant from what was in the POD !!! } } #### sub fake_module { my ($class, $modname, %subs) = @_; # replace methods in $modname with those in %subs $INC{ $modname . '.pm' } = 1; # pretend we have already loaded the module foreach my $sub (keys %subs) { # for each implementation provided ... *{ $module . '::' . $sub } = $subs{ $sub }; # store the provided implementation in the symbol table } }