Created
May 20, 2015 08:08
-
-
Save ktat/8dc4028a1e68fe45c43d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/perl | |
use strict; | |
use warnings; | |
package Test; | |
use Carp; | |
sub hoge { | |
Carp::croak("die"); # mesasge is "die at goto_test.pl line 22." | |
print join " ", @_; | |
}; | |
package main; | |
sub xxx {my ($a,$b) = @_; | |
$a = 2, $b = 3; @_ = ($a, $b); | |
goto &Test::hoge | |
} | |
xxx(1,2) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment