Merge git://factorcode.org/git/factor
commit
dcd2ce7b57
|
@ -15,12 +15,12 @@ crossref off
|
|||
"resource:core/bootstrap/syntax.factor" parse-file
|
||||
|
||||
"resource:core/cpu/" architecture get {
|
||||
{ "x86.32" "x86/32" }
|
||||
{ "x86.64" "x86/64" }
|
||||
{ "linux-ppc" "ppc/linux" }
|
||||
{ "macosx-ppc" "ppc/macosx" }
|
||||
{ "arm" "arm" }
|
||||
} at "/bootstrap.factor" 3append parse-file
|
||||
{ "x86.32" "x86/32" }
|
||||
{ "x86.64" "x86/64" }
|
||||
{ "linux-ppc" "ppc/linux" }
|
||||
{ "macosx-ppc" "ppc/macosx" }
|
||||
{ "arm" "arm" }
|
||||
} at "/bootstrap.factor" 3append parse-file
|
||||
|
||||
"resource:core/bootstrap/layouts/layouts.factor" parse-file
|
||||
|
||||
|
@ -626,7 +626,7 @@ builtins get num-tags get tail f union-class define-class
|
|||
{ "<float-array>" "float-arrays" }
|
||||
{ "curry" "kernel" }
|
||||
{ "<tuple-boa>" "tuples.private" }
|
||||
{ "class-hash" "kernel.private" }
|
||||
{ "class-hash" "kernel.private" }
|
||||
{ "callstack>array" "kernel" }
|
||||
{ "innermost-frame-quot" "kernel.private" }
|
||||
{ "innermost-frame-scan" "kernel.private" }
|
||||
|
|
|
@ -58,17 +58,17 @@ M: f pprint* drop \ f pprint-word ;
|
|||
! Strings
|
||||
: ch>ascii-escape ( ch -- str )
|
||||
H{
|
||||
{ CHAR: \e CHAR: \\e }
|
||||
{ CHAR: \n CHAR: \\n }
|
||||
{ CHAR: \r CHAR: \\r }
|
||||
{ CHAR: \t CHAR: \\t }
|
||||
{ CHAR: \0 CHAR: \\0 }
|
||||
{ CHAR: \\ CHAR: \\\\ }
|
||||
{ CHAR: \" CHAR: \\\" }
|
||||
{ CHAR: \e CHAR: e }
|
||||
{ CHAR: \n CHAR: n }
|
||||
{ CHAR: \r CHAR: r }
|
||||
{ CHAR: \t CHAR: t }
|
||||
{ CHAR: \0 CHAR: 0 }
|
||||
{ CHAR: \\ CHAR: \\ }
|
||||
{ CHAR: \" CHAR: \" }
|
||||
} at ;
|
||||
|
||||
: unparse-ch ( ch -- )
|
||||
dup ch>ascii-escape [ ] [ ] ?if , ;
|
||||
dup ch>ascii-escape [ "\\" % ] [ ] ?if , ;
|
||||
|
||||
: do-string-limit ( str -- trimmed )
|
||||
string-limit get [
|
||||
|
|
|
@ -38,7 +38,7 @@ M: string set-nth-unsafe
|
|||
>r >fixnum >r >fixnum r> r> set-string-nth ;
|
||||
|
||||
M: string clone
|
||||
(clone) dup string-aux clone over set-string-aux ;
|
||||
(clone) dup string-aux clone over set-string-aux ;
|
||||
|
||||
M: string resize resize-string ;
|
||||
|
||||
|
|
Loading…
Reference in New Issue