24 lines
441 B
Factor
24 lines
441 B
Factor
IN: temporary
|
|
|
|
USE: parser
|
|
USE: test
|
|
USE: words
|
|
USE: strings
|
|
USE: kernel
|
|
|
|
DEFER: foo
|
|
|
|
": foo 2 2 + . ; parsing" eval
|
|
|
|
[ [ ] ] [ "USE: temporary foo" parse ] unit-test
|
|
|
|
": foo 2 2 + . ;" eval
|
|
|
|
[ [ POSTPONE: foo ] ] [ "USE: temporary foo" parse ] unit-test
|
|
|
|
! Test > 1 ( ) comment; only the first one should be used.
|
|
[ t ] [
|
|
"a" "IN: temporary : foo ( a ) ( b ) ;" parse drop word
|
|
"stack-effect" word-prop string-contains?
|
|
] unit-test
|