diff options
| author | Gabriel Schneider <[email protected]> | 2026-09-29 02:12:34 -0300 |
|---|---|---|
| committer | Gabriel Schneider <[email protected]> | 2026-10-01 00:12:15 -0300 |
| commit | 69b6d714b7fc7788a1bf1c2305262a6e861253e8 (patch) | |
| tree | 2ad39a1ec58a25c4b4e65b517ba29ea86dc5a3a5 /docs | |
| parent | 3db73735e9a8d88878bc9ee343f226c033320913 (diff) | |
| download | pardes-69b6d714b7fc7788a1bf1c2305262a6e861253e8.tar.gz pardes-69b6d714b7fc7788a1bf1c2305262a6e861253e8.zip | |
A line address past the last newline is sam's empty line there
Forward line addresses followed acme's number(), which refuses the empty
line after a text's last newline, so 1 of an empty buffer and 2 of "a\n"
were out of range and Edit 1i/header/ failed on an empty file. They now
follow sam's lineaddr (editors/sam/address.c:180-215): #0,#0 and #2,#2.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Diffstat (limited to 'docs')
| -rw-r--r-- | docs/fs.md | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -483,6 +483,12 @@ pane) and `exec` alike; an unclosed group is refused (``unmatched `{'``). bash's builtin `printf` writes a line at a time, so write a block with a heredoc or `env printf`. +A line number counts newlines as sam's lineaddr does (editors/sam/ +address.c:180), so the empty line just past a text's last newline is an +address: `1` of an empty text is `#0,#0`, `2` of `a\n` is `#2,#2`, and +`Edit 1i/header/` on an empty file inserts; a line past that is `address +out of range`. + `line:col` is a pardes extension to sam's addresses, the spelling Look takes in `file:12:5`: `12:5` is the point at line 12, column 5, and it composes like any simple address (`12:5,14:1`, `12:5+#3`). The column is |
