YAML::PP - Add your own constructor

$yp->schema->add_resolver( tag => "tag:yaml.org,2002:int", match => [ regex => qr/^ ([IVXLCM]+) \z/x => sub { return { I =>1, II =>2, III =>3, IV=>4, V=>5, VI=>6, VII=>7, VIII=>8, IX=>9, X=>10, }->{ $_[0] }; }], implicit => 1, # allow matching without tag );
--- - VII # seven - 7 # and another seven
Slide 81/88 BACK UP NEXT next: ( space / -> / page up ) | previous: ( backspace / <- / page down ) | next page: ( shift + page down ) | previous page: ( shift + page up ) | index: ( arrow-up )