Commit e99acd5
Fix CAST parsing to handle expression type arguments like 'Str'||'ing'
When parsing CAST(x, type) with comma syntax, check if the type string
is followed by an operator (CONCAT, PLUS, MINUS) before consuming it.
If so, parse it as a full expression to handle cases like:
CAST(123, 'Str'||'ing')
Fixes 03011_definitive_guide_to_cast/stmt36.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>1 parent 7a62b45 commit e99acd5
File tree
2 files changed
+5
-7
lines changed- parser
- testdata/03011_definitive_guide_to_cast
2 files changed
+5
-7
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1557 | 1557 | | |
1558 | 1558 | | |
1559 | 1559 | | |
1560 | | - | |
| 1560 | + | |
| 1561 | + | |
| 1562 | + | |
1561 | 1563 | | |
1562 | 1564 | | |
1563 | 1565 | | |
| |||
1597 | 1599 | | |
1598 | 1600 | | |
1599 | 1601 | | |
1600 | | - | |
| 1602 | + | |
1601 | 1603 | | |
1602 | 1604 | | |
1603 | 1605 | | |
| |||
Lines changed: 1 addition & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
2 | | - | |
3 | | - | |
4 | | - | |
5 | | - | |
| 1 | + | |
0 commit comments