Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the YAML CPAN distribution.

Report information
The Basics
Id: 13500
Status: resolved
Priority: 0/
Queue: YAML

People
Owner: Nobody in particular
Requestors: ed [...] donorware.com
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: (no value)
Fixed in: (no value)



Subject: Load(Dump("|foo")) fails
YAML-0.39, Perl 5.86, on OS X Tiger. Example of bug with error message: $ perl -MYAML -e 'YAML::Load(YAML::Dump("|foo"))' --- !perl/YAML::Error code: YAML_PARSE_ERR_TEXT_AFTER_INDICATOR msg: No text allowed after indicator line: 0 document: 1 ... at -e line 1 I haven't yet tried to fix this one. If I manage to I will amend a patch.
From: ed [...] donorware.com
fix is a one liner: diff -u YAML.pm.orig YAML.pm --- YAML.pm.orig 2005-07-01 11:44:15.000000000 -0400 +++ YAML.pm 2005-07-01 11:52:55.000000000 -0400 @@ -589,7 +589,7 @@ sub is_valid_plain { return 0 unless length $_[0]; # refer: parse_inline_simple() - return 0 if $_[0] =~ /^[\s\{\[\~\`\'\"\!\@\#\%\&\*\^]/; + return 0 if $_[0] =~ /^[\s\{\[\~\`\'\"\!\@\#\%\&\*\^\|]/; return 0 if $_[0] =~ /[\{\[\]\},]/; return 0 if $_[0] =~ /[:\-\?]\s/; return 0 if $_[0] =~ /\s#/;