VALUE: jis208
VALUE: jis212
-"vocab:io/encodings/iso2022/201.txt" flat-file>biassoc to: jis201
-"vocab:io/encodings/iso2022/208.txt" flat-file>biassoc to: jis208
-"vocab:io/encodings/iso2022/212.txt" flat-file>biassoc to: jis212
+"vocab:io/encodings/iso2022/201.txt" flat-file>biassoc \ jis201 set-value
+"vocab:io/encodings/iso2022/208.txt" flat-file>biassoc \ jis208 set-value
+"vocab:io/encodings/iso2022/212.txt" flat-file>biassoc \ jis212 set-value
VALUE: ascii
-128 unique >biassoc to: ascii
+128 iota unique >biassoc \ ascii set-value
TUPLE: iso2022-state type ;
M: iso2022 <decoder>
make-iso-coder <decoder> ;
-<< SYNTAX: ESC HEX: 16 parsed ; >>
+<< SYNTAX: ESC 0x16 suffix! ; >>
CONSTANT: switch-ascii B{ ESC CHAR: ( CHAR: B }
CONSTANT: switch-jis201 B{ ESC CHAR: ( CHAR: J }
char encoding type>> value? [
char find-type
[ stream stream-write ]
- [ encoding (>>type) ] bi*
+ [ encoding type<< ] bi*
] unless
char encoding type>> value-at stream stream-write-num ;
stream stream-read1 {
{ ESC [
stream read-escape [
- encoding (>>type)
+ encoding type<<
stream encoding decode-char
] [ replacement-char ] if*
] }