[YANGTOOLS-1458] Instance identifier parser : handle inner quotes within quoted strings Created: 25/Oct/22 Updated: 09/Jan/23 Resolved: 09/Jan/23 |
|
| Status: | Resolved |
| Project: | yangtools |
| Component/s: | xpath |
| Affects Version/s: | None |
| Fix Version/s: | 8.0.10, 10.0.3, 9.0.7 |
| Type: | Bug | Priority: | Medium |
| Reporter: | Ruslan Kashapov | Assignee: | Robert Varga |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||
| Description |
|
actual: "/foo:foo[. = 'i\'am']" "/foo:foo[foo:bar = \"quot\\\"ed\"]"; expected: escaped quotes should be treated as part of quoted string |
| Comments |
| Comment by Robert Varga [ 25/Oct/22 ] |
|
The first is actually not valid: YANG does not allow escaping inside single-quoted strings (see https://www.rfc-editor.org/rfc/rfc7950#section-6.1.3). The second is valid, though and will require some surgery to switch to modal lexer – just like we have for YANG itself |