Digest #171 2022-02-13

Contributions

[219] 2022-02-12 16:13:14 flaagel wrote:

example - Forth Programmer's Handbook

defines an interpretation semantics for S" as:

'If interpreting, return the address and length of the following string, terminated by ", which is in a temporary buffer.'

This particular semantics seems to have been withdrawn from the Forth2012 specification, Any particular rationale for that?

Replies

[r784] 2022-02-12 18:23:04 flaagel replies:

example - Forth Programmer's Handbook

Also, I think the outcome of the test should not depend on the current BASE.

T{ GC4 DROP DUP C@ SWAP CHAR+ C@ -> $58 $59 }T

works fine over here...


[r785] 2022-02-12 18:39:03 ruv replies:

example - Forth Programmer's Handbook

This particular semantics seems to have been withdrawn from the Forth2012 specification

The Forth 2012 standard (as well as Forth 94) specifies two versions of the the word S": in the CORE word set (the minimal conformance level), and in the optional File-Access word set. In the former version interpretation semantics are undefined, but in the latter version they are defined.

So, take a look on the glossary entry for FILE S" — Forth Programmer's Handbook describes this version.