hectorcorrea / marcli

MARC command line parser
MIT License
117 stars 8 forks source link

panic: Extraneous field terminator #3

Closed sunshineplan closed 3 years ago

sunshineplan commented 3 years ago

When parsing some of my files, I encounter this panic in process. I checked my files found its data is something like [31 xxx 31 xxx] or [xxxxx 31 31 xxxxxx].

The specification only says: The subfield code consists of a delimiter (ASCII 1F (hex)) followed by a data element identifier., not clearly don't allow a delimiter without a data element identifier and its data element. In my opinion these emtpy subfield code is meanless, but they are not harmful, so no need to treat it as error.