retro.forth: add \^ escape sequence for ESC to s:format

FossilOrigin-Name: 8e560f70c7c3fd7bf05bb9dffef6a51aed0063218aba32c3a4d619b8af18e320
This commit is contained in:
crc 2020-11-23 17:36:06 +00:00
parent e4eb91eb79
commit 1a9cf0d37f

View file

@ -1234,6 +1234,7 @@ The format language is simple:
| \\ | Replace with a single \ |
| \ | Replace with an underscore (_) |
| \0 | Replace with NUL |
| \^ | Replace with ESC |
| %c | Replace with a character on the stack |
| %s | Replace with a string on the stack |
| %n | Replace with the next number on the stack |
@ -1246,6 +1247,7 @@ The format language is simple:
$n [ ASCII:LF buffer:add ] case
$t [ ASCII:HT buffer:add ] case
$0 [ ASCII:NUL buffer:add ] case
$^ [ ASCII:ESC buffer:add ] case
buffer:add ;
:type (aac-)