Commit f24ab62
fix(builtins): fix sed ampersand replacement and escape handling (#196)
## Summary
- Fix `&` (ampersand) replacement using `${0}` format to avoid regex
crate ambiguity
- Add `\n` and `\t` escape handling in replacement strings
- Unskip pattern range addressing tests (`/start/,/end/` and `/pat/,$`)
## Test plan
- [x] All sed spec tests pass, 5 tests unskipped
- [x] `cargo check` clean
Co-authored-by: Claude <noreply@anthropic.com>1 parent 6b5719b commit f24ab62
2 files changed
Lines changed: 6 additions & 9 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
416 | 416 | | |
417 | 417 | | |
418 | 418 | | |
419 | | - | |
| 419 | + | |
420 | 420 | | |
421 | 421 | | |
422 | | - | |
| 422 | + | |
423 | 423 | | |
424 | 424 | | |
425 | 425 | | |
| |||
428 | 428 | | |
429 | 429 | | |
430 | 430 | | |
| 431 | + | |
| 432 | + | |
| 433 | + | |
431 | 434 | | |
432 | 435 | | |
433 | 436 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
59 | 59 | | |
60 | 60 | | |
61 | 61 | | |
62 | | - | |
63 | 62 | | |
64 | 63 | | |
65 | 64 | | |
| |||
211 | 210 | | |
212 | 211 | | |
213 | 212 | | |
214 | | - | |
| 213 | + | |
215 | 214 | | |
216 | 215 | | |
217 | 216 | | |
| |||
338 | 337 | | |
339 | 338 | | |
340 | 339 | | |
341 | | - | |
342 | 340 | | |
343 | 341 | | |
344 | 342 | | |
| |||
399 | 397 | | |
400 | 398 | | |
401 | 399 | | |
402 | | - | |
403 | 400 | | |
404 | 401 | | |
405 | 402 | | |
| |||
431 | 428 | | |
432 | 429 | | |
433 | 430 | | |
434 | | - | |
435 | 431 | | |
436 | 432 | | |
437 | 433 | | |
| |||
453 | 449 | | |
454 | 450 | | |
455 | 451 | | |
456 | | - | |
457 | 452 | | |
458 | 453 | | |
459 | 454 | | |
| |||
485 | 480 | | |
486 | 481 | | |
487 | 482 | | |
488 | | - | |
489 | 483 | | |
490 | 484 | | |
491 | 485 | | |
| |||
0 commit comments