Lines Matching refs:pkg
182 my $pkg = $obj->root();
186 $pkg = "main::$pkg\::"; # expand to full symbol table name
187 ($stem, $leaf) = $pkg =~ m/(.*::)(\w+::)$/;
193 #warn "erase($pkg) stem=$stem, leaf=$leaf";
274 my $pkg = shift;
281 croak("Package \"$pkg\" does not exist")
282 unless keys %{"$pkg\::"};
288 # warn "share_from $pkg $type $var";
290 *{$root."::$var"} = (!$type) ? \&{$pkg."::$var"}
291 : ($type eq '&') ? \&{$pkg."::$var"}
292 : ($type eq '$') ? \${$pkg."::$var"}
293 : ($type eq '@') ? \@{$pkg."::$var"}
294 : ($type eq '%') ? \%{$pkg."::$var"}
295 : ($type eq '*') ? *{$pkg."::$var"}
299 $obj->share_record($pkg, $vars) unless $no_record or !$vars;
305 my $pkg = shift;
309 @{$shares}{@$vars} = ($pkg) x @$vars if @$vars;
316 my($var, $pkg);
317 while(($var, $pkg) = each %$shares) {
318 # warn "share_redo $pkg\:: $var";
319 $obj->share_from($pkg, [ $var ], 1);
682 Consider a function foo() in package pkg compiled outside a compartment
685 normally, $pkg::foo will be set to 1. If foo() is called from the
686 compartment (by whatever means) then instead of setting $pkg::foo, the
687 eval will actually set $Root::pkg::foo.