diff options
| author | Bruce Hill <bruce@bruce-hill.com> | 2024-09-09 01:14:33 -0400 |
|---|---|---|
| committer | Bruce Hill <bruce@bruce-hill.com> | 2024-09-09 01:14:33 -0400 |
| commit | 11c560ebccfa3eabb939dafc4139be92edd26842 (patch) | |
| tree | 43af12019ce7d133a539a0b3a9388e07e82acec6 /parse.c | |
| parent | 13a9304decb86450a2a0e9cc756da4c2d373c929 (diff) | |
More path stuff including some methods
Diffstat (limited to 'parse.c')
| -rw-r--r-- | parse.c | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -1321,6 +1321,10 @@ PARSER(parse_path) { } case '$': { const char *interp_start = pos; + + if (pos > chunk_start) + chunk_text = CORD_asprintf("%r%.*s", chunk_text, (size_t)(pos - chunk_start), chunk_start); + if (chunk_text) { ast_t *literal = NewAST(ctx->file, chunk_start, pos, TextLiteral, .cord=chunk_text); chunks = new(ast_list_t, .ast=literal, .next=chunks); |
