diff options
| author | Bruce Hill <bruce@bruce-hill.com> | 2026-01-19 20:51:26 -0500 |
|---|---|---|
| committer | Bruce Hill <bruce@bruce-hill.com> | 2026-01-19 20:52:23 -0500 |
| commit | f905f1e4d1c77410931dc5ebfd8bcf466864a3e2 (patch) | |
| tree | 32d52ad87f303237e451c90c1a33b12217a1c6e5 /src/parse/utils.c | |
| parent | a36f149d0837f4424aeda1a1853f08c27aeafa44 (diff) | |
Allow parsing `123.foo()` as `(123).foo()`
Diffstat (limited to 'src/parse/utils.c')
| -rw-r--r-- | src/parse/utils.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/parse/utils.c b/src/parse/utils.c index 03e0ebcd..2df3f1a9 100644 --- a/src/parse/utils.c +++ b/src/parse/utils.c @@ -57,6 +57,12 @@ size_t match(const char **pos, const char *target) { return len; } +bool is_xid_start_next(const char *pos) { + ucs4_t point = 0; + u8_next(&point, (const uint8_t *)pos); + return uc_is_property_xid_start(point); +} + bool is_xid_continue_next(const char *pos) { ucs4_t point = 0; u8_next(&point, (const uint8_t *)pos); |
