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: 18523
Status: resolved
Priority: 0/
Queue: YAML

People
Owner: Nobody in particular
Requestors: Bernhard.Schmalhofer [...] biomax.de
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in: 0.58
Fixed in: (no value)



Subject: inconsisten indentation error with '<<' as first key in mapping
Hi, in an YAML based config module I have added support for the special key '<<', used for merging entries. However I ran into a YAML_PARSE_ERR_INCONSISTENT_INDENTATION error, when '<<' is the first key in a mapping. This look like a bug to me. So far everything looks OK when '<<' is the second key in a mapping. I have attached a short example. Regards, Bernhard
Subject: yaml_indent.pl
use strict; use warnings; use 5.8.0; use YAML 0.58 (); use Data::Dumper (); my ( $arrref_ok ) = YAML::Load(<<'END_YAML'); - arr_key_2: arr_val_2 <<: arr_val_1 END_YAML # my ( $arrref_nok ) = ( [] ); my ( $arrref_nok ) = YAML::Load(<<'END_YAML'); - <<: arr_val_1 arr_key_2: arr_val_2 END_YAML print Data::Dumper::Dumper( $arrref_ok, $arrref_nok );
This issue has been copied to: https://github.com/ingydotnet/yaml-pm/issues/58 please take all future correspondence there. This ticket will remain open but please do not reply here. This ticket will be closed when the github issue is dealt with.
Thanks, fixed in 1.25