On Fri, 11 Sep 2020 at 01:00, Glenn Knickerbocker <n...@bestweb.net> wrote:

> pipe literal 123| specs 1-* v2c 1.3 right | cons
> >   1
>
> That's just wrong.


Yes, the x0001 that goes in is not the "length of the input field" but
rather what still fits in the output field after we reserved two bytes for
the length. There's been too much water through the pipes to change that or
to consider it an error. The best I could do is change the book to explain
what happens when the output field is too short.

Fortunately you have the "addrdw cms" now that probably does what you meant
to do. While I like "parcel" for the reverse operation, it's harder to make
that work on multiple records.

I'll think about the wording of the error message (like "length and field"
rather than "field length"). Considering what the code does now, v2c into
an output field of length 2 is not very useful (it would produce x0000). If
you just wanted to know the length of the input field, there are a few
different idioms.

Sir Rob the Plumber

Reply via email to