Parse::Binary::Nested: track parsed bytes
authorMischa Poslawsky <wormy@shiar.org>
Tue, 3 Mar 2009 17:59:16 +0000 (18:59 +0100)
committerMischa Poslawsky <wormy@shiar.org>
Wed, 4 Mar 2009 15:02:45 +0000 (16:02 +0100)
commitce0df5c87882d5275a22ab3bb3f5642c577927b6
tree541d638d39e6a0a8f2ec575229c1299094e01402
parent5f543f9395f3a885ee9b751e98d069b9ed54f885
Parse::Binary::Nested: track parsed bytes

Reparse template values ourself, in order to:
- Put multiple data in a single value (for example 'CC' will return
  an array with the two bytes, instead of screwing up all following
  elements);
- Know the amount of bytes read, allowing the current position to be
  returned by the special '=.' declaration.

Also, the special case 'Ca$NUM' is now to be given as 'C/a$NUM'.
This solution should be much better (logically combines C/a and a$NUM)
and unambiguous (this syntax is invalid with CORE::unpack, so no
unexpected results).
Parse/Binary/Nested.pm
parse-wormedit