/[suikacvs]/markup/html/whatpm/Whatpm/HTML.pm.src
Suika

Diff of /markup/html/whatpm/Whatpm/HTML.pm.src

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.137 by wakaba, Sun May 18 03:46:27 2008 UTC revision 1.138 by wakaba, Sun May 18 04:15:48 2008 UTC
# Line 332  my $c1_entity_char = { Line 332  my $c1_entity_char = {
332  }; # $c1_entity_char  }; # $c1_entity_char
333    
334  sub parse_byte_string ($$$$;$) {  sub parse_byte_string ($$$$;$) {
335      my $self = shift;
336      my $charset_name = shift;
337      open my $input, '<', ref $_[0] ? $_[0] : \($_[0]);
338      return $self->parse_byte_stream ($charset_name, $input, @_[1..$#_]);
339    } # parse_byte_string
340    
341    sub parse_byte_stream ($$$$;$) {
342    my $self = ref $_[0] ? shift : shift->new;    my $self = ref $_[0] ? shift : shift->new;
343    my $charset_name = shift;    my $charset_name = shift;
344    open my $byte_stream, '<', ref $_[0] ? $_[0] : \($_[0]);    my $byte_stream = $_[0];
345    
346    my $onerror = $_[2] || sub {    my $onerror = $_[2] || sub {
347      my (%opt) = @_;      my (%opt) = @_;
# Line 546  sub parse_byte_string ($$$$;$) { Line 553  sub parse_byte_string ($$$$;$) {
553      $return = $self->parse_char_stream ($char_stream, @args);      $return = $self->parse_char_stream ($char_stream, @args);
554    };    };
555    return $return;    return $return;
556  } # parse_byte_string  } # parse_byte_stream
557    
558  ## NOTE: HTML5 spec says that the encoding layer MUST NOT strip BOM  ## NOTE: HTML5 spec says that the encoding layer MUST NOT strip BOM
559  ## and the HTML layer MUST ignore it.  However, we does strip BOM in  ## and the HTML layer MUST ignore it.  However, we does strip BOM in

Legend:
Removed from v.1.137  
changed lines
  Added in v.1.138

admin@suikawiki.org
ViewVC Help
Powered by ViewVC 1.1.24