Commit b9cbdad
authored
Fix a bug in edireader a missing optional elem would cause subsequent elem parsing fail (#109)
Imagine a seg `ISA*e2` (elem delim is `'*'`). Imagine the elem decl is:
```
{ "name": "e1", "index": 1, "empty_if_missing": true },
{ "name": "e2", "index": 2 }
```
Now e1 is optional, thus schema writer specifies "empty_if_missing". However the current single-linear-scan
in `ediReader.rawSegToNode` will scan all the way to the end, thus causing the subsequent `e2` scanning to
fail.1 parent 2369d89 commit b9cbdad
File tree
4 files changed
+6
-35
lines changed- extensions/omniv21/fileformat/edi
- .snapshots
4 files changed
+6
-35
lines changedLines changed: 4 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
10 | | - | |
11 | | - | |
12 | | - | |
13 | | - | |
14 | 10 | | |
15 | 11 | | |
16 | 12 | | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
17 | 17 | | |
18 | 18 | | |
19 | 19 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
250 | 250 | | |
251 | 251 | | |
252 | 252 | | |
253 | | - | |
254 | | - | |
255 | 253 | | |
256 | 254 | | |
| 255 | + | |
257 | 256 | | |
258 | 257 | | |
259 | 258 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
6 | | - | |
7 | 6 | | |
8 | 7 | | |
9 | 8 | | |
| |||
36 | 35 | | |
37 | 36 | | |
38 | 37 | | |
39 | | - | |
40 | 38 | | |
41 | 39 | | |
42 | 40 | | |
| |||
48 | 46 | | |
49 | 47 | | |
50 | 48 | | |
51 | | - | |
52 | | - | |
53 | | - | |
54 | | - | |
55 | | - | |
56 | | - | |
57 | | - | |
58 | | - | |
59 | | - | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
11 | | - | |
12 | | - | |
13 | | - | |
14 | | - | |
15 | | - | |
16 | | - | |
17 | | - | |
18 | | - | |
19 | | - | |
20 | | - | |
21 | | - | |
22 | | - | |
23 | | - | |
24 | | - | |
25 | | - | |
26 | | - | |
27 | | - | |
28 | 11 | | |
29 | 12 | | |
30 | 13 | | |
| |||
78 | 61 | | |
79 | 62 | | |
80 | 63 | | |
81 | | - | |
| 64 | + | |
82 | 65 | | |
0 commit comments