- Timestamp:
- 07/31/08 16:58:59 (5 months ago)
- Location:
- perl5/Pugs-Compiler-Perl6/lib/Pugs
- Files:
-
- 2 modified
-
Emitter/Perl6/Perl5.pm (modified) (1 diff)
-
Runtime/Perl6Prelude.pm (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
perl5/Pugs-Compiler-Perl6/lib/Pugs/Emitter/Perl6/Perl5.pm
r21650 r21654 1643 1643 } ); 1644 1644 } 1645 if ( exists $n->{exp2}{pair} 1646 && $n->{exp2}{pair}{key}{single_quoted} eq 'e' 1647 && $n->{exp2}{pair}{value}{num} eq 1 1648 ) 1649 { 1650 # $filename ~~ :e 1651 return "( -e " . _emit( $n->{exp1} ) . ")"; 1652 } 1645 1653 return _emit( $n->{exp1} ) . ' =~ (ref' . emit_parenthesis( $n->{exp2} ).' eq "Regexp" '. 1646 1654 ' ? '._emit($n->{exp2}). -
perl5/Pugs-Compiler-Perl6/lib/Pugs/Runtime/Perl6Prelude.pm
r21577 r21654 23 23 # sub sleep($seconds) is export { use v5; CORE::sleep($seconds); use v6; } 24 24 25 sub open($file ) { use v5; my $fh = IO::File->new; $fh->open($file) || warn "can't open file $file"; $fh; use v6; }25 sub open($file, :$w? ) { use v5; my $fh = IO::File->new; $fh->open($file, ($w ? 'w' : ()) ) || warn "can't open file $file"; $fh; use v6; } 26 26 27 27 module Pugs::Internals;
