summaryrefslogtreecommitdiff
path: root/lib/AutoLoader.pm
blob: dba8ca2f5fb1617497df7ed91d27f1f8b212f389 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
package AutoLoader;

AUTOLOAD {
    my $name = "auto/$AUTOLOAD.al";
    $name =~ s#::#/#g;
    eval {require $name};
    if ($@) {
	($p,$f,$l) = caller($AutoLevel);
	$@ =~ s/ at .*\n//;
	die "$@ at $f line $l\n";
    }
    goto &$AUTOLOAD;
}

1;