Perlito5
view release on metacpan - search on metacpan
view release on metacpan or search on metacpan
lib/Perlito5/Runtime.pm view on Meta::CPAN
package Perlito5;
use Perlito5::Grammar::Scope;
use strict;
our @PERL_VERSION = ( 5, 26, 0 );
$^O = 'perlito5' unless defined $^O;
$/ = chr(10) unless defined $/;
$" = ' ' unless defined $";
$, = undef unless defined $,;
$! = '' unless defined $!;
$; = chr(28) unless defined $;;
$? = 0 unless defined $?;
# $[ = 0 unless defined $[; # "assignment to $[ is deprecated"
$] = sprintf( "%d.%03d%03d", @PERL_VERSION ) unless $]; # $] is defined(), but ${"main::]"} is not
$^V = bless( { 'original' => 'v' . join( ".", @PERL_VERSION ), # v5.26.0
'qv' => 1,
'version' => [ @PERL_VERSION ]
}, 'version' )
unless defined $^V;
$^H = 0;
%^H = ();
our $EXPAND_USE = 1;
our $EMIT_USE = 0;
our $WARNINGS = 0;
our $UTF8 = 0;
our $BYTES = 0;
our @CALLER = ();
our %DATA_SECTION = (); # contents of the __DATA__ sections per package
our $PKG_NAME = ''; # current package being compiled
our $LINE_NUMBER = 0; # current line number being compiled
our $FILE_NAME = ''; # current file name being compiled
our %FORMAT = (); # 'format' statements - hash of subs
# information about the current compilation process
our $GLOBAL = {};
our @BASE_SCOPE = ( Perlito5::Grammar::Scope->new_base_scope() );
our $CLOSURE_SCOPE = 0; # variables that are in scope in the current closure being compiled
our @SCOPE_STMT = ();
our @END_BLOCK = (); # END block LIFO - array of subs
our @INIT_BLOCK = (); # INIT block FIFO - array of subs
our @CHECK_BLOCK = (); # CHECK block LIFO - array of subs
our @UNITCHECK_BLOCK = (); # UNITCHECK block LIFO - array of subs
our %BEGIN_SCRATCHPAD = (); # list of "my" variables captured in BEGIN blocks
our $PROTO = {};
our %VARS = (); # implements "use vars"
# $Perlito5::STRICT_* - See Perlito5X::strict.pm
# the Perl-to-Java compiler uses this syntax for "annotations":
# package Put { import => 'java.Put' };
# annotations are stored as namespace + AST
our @ANNOTATION;
sub set_global_phase {
my $phase = shift;
local $@;
eval { ${^GLOBAL_PHASE} = $phase };
}
our $ID = 100; # generic "id" source; increment after use
# list of packages that "exist" - this is used by the indirect-object parser
our $PACKAGES = {
STDERR => 1,
STDOUT => 1,
STDIN => 1,
main => 1,
strict => 1,
warnings => 1,
utf8 => 1,
bytes => 1,
encoding => 1,
view all matches for this distributionview release on metacpan - search on metacpan
( run in 1.902 second using v1.00-cache-2.02-grep-82fe00e-cpan-d29e8ade9f55 )