-
Notifications
You must be signed in to change notification settings - Fork 2
everywhere
TurtleKitty edited this page May 19, 2017
·
2 revisions
This allows the programmer to define variables and procedures to be available during compile time and run time.
(def runtime-foo 1)
(proc runtime-bar (x) (+ x 10))
(runtime-bar runtime-foo)
-> Ok!
(op baz ()
(... runtime-foo or runtime-bar ...))
-> ERROR
(compile-eval
(def compile-time-foo 2)
(proc compile-time-bar (x) (+ x 20)))
(op baz ()
(... compile-time-foo or compile-time-bar ...))
-> Ok!
(compile-time-bar compile-time-foo)
-> ERROR
(everywhere
(def everywhere-foo 3)
(proc everywhere-bar (x) (+ x 30)))
(op baz ()
(... everywhere-foo or everywhere-bar ...))
-> Ok!
(everywhere-bar everywhere-foo)
-> Also Ok!