Skip to content

Latest commit

 

History

History
17 lines (9 loc) · 949 Bytes

parsee-case-csv.md

File metadata and controls

17 lines (9 loc) · 949 Bytes

ParSEE case study: CSV decoder processes the same part of input twice

NOTE ParSEE wasn't designed for this use case, and at the moment won't help identify O(n^2) rules, e.g. [any [not to target skip]]
NOTE At the moment this feature doesn't work on GTK backend due a to platform discrepancy in RTD

Double processing incurs additional time cost and should be avoided in codecs. Some cases of such double processing are directly visible in the UI of ParSEE, and can help to improve the code.

Here's an example from CSV codec:

As can be seen, single-value rule matches the last value in every line, then its parent rule fails as it doesn't see a delimiter (comma) ahead, and line-rule lets single-value match again, which is likely not by design.