Changeset 22901 for src

Show
Ignore:
Timestamp:
11/06/08 18:51:14 (2 months ago)
Author:
lwall
Message:

[Cursor] use of cat deemed less than useful

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • src/perl6/Cursor.pmc

    r22900 r22901  
    133133    local $::VOID = 1 if not defined wantarray; 
    134134    local $::COMPILING::FILE = $file; 
    135     my $text = Encode::decode('utf8', `cat $file`); 
     135    open(FILE, '<:utf8', $file) or die "Can't open $file: $!\n"; 
     136    my $text; 
     137    { 
     138        local $/; 
     139        $text = <FILE>; 
     140        close FILE; 
     141    } 
    136142    $class->new($text)->$rule(); 
    137143}