aboutsummaryrefslogtreecommitdiff
path: root/lux-r/source/program.lux
diff options
context:
space:
mode:
authorEduardo Julian2022-03-30 15:25:06 -0400
committerEduardo Julian2022-03-30 15:25:06 -0400
commit9df5ff6abc6e95c766d1907c5a9fee00730e749a (patch)
tree8614095c2c2a3a5cd195f9e6da53f47c88891381 /lux-r/source/program.lux
parent8ebc505f1be8e103039d220b2d824dd687777f24 (diff)
Re-named ffi.as to "is", and ffi.check to "as", to line the names up with normal type-annotation macros.
Diffstat (limited to 'lux-r/source/program.lux')
-rw-r--r--lux-r/source/program.lux14
1 files changed, 7 insertions, 7 deletions
diff --git a/lux-r/source/program.lux b/lux-r/source/program.lux
index 0dd304ee0..3fa4acc3c 100644
--- a/lux-r/source/program.lux
+++ b/lux-r/source/program.lux
@@ -195,7 +195,7 @@
... (function (_ sub_value)
... (let [sub_value (as java/lang/Object sub_value)]
... (`` (<| (~~ (template [<type> <then>]
- ... [(case (ffi.check <type> sub_value)
+ ... [(case (ffi.as <type> sub_value)
... {.#Some sub_value}
... (`` (|> sub_value (~~ (template.splice <then>))))
... {.#None})]
@@ -369,7 +369,7 @@
(wrap [(|> tag (as java/lang/Long) java/lang/Long::intValue)
(case (|> host_object
(org/renjin/sexp/ListVector::get_field runtime.variant_flag_field)
- (ffi.check org/renjin/sexp/Null))
+ (ffi.as org/renjin/sexp/Null))
{.#Some _}
(is Any (ffi.null))
@@ -381,10 +381,10 @@
(Reader org/renjin/sexp/ListVector)
(case [(|> host_object
(org/renjin/sexp/ListVector::get_field runtime.i64_high_field)
- (ffi.check org/renjin/sexp/IntArrayVector))
+ (ffi.as org/renjin/sexp/IntArrayVector))
(|> host_object
(org/renjin/sexp/ListVector::get_field runtime.i64_low_field)
- (ffi.check org/renjin/sexp/IntArrayVector))]
+ (ffi.as org/renjin/sexp/IntArrayVector))]
[{.#Some high} {.#Some low}]
{try.#Success (runtime.lux_i64 (org/renjin/sexp/SEXP::asInt high)
(org/renjin/sexp/SEXP::asInt low))}
@@ -418,7 +418,7 @@
(Reader java/lang/Object)
(exec
... ("lux io log" (exception.construct ..unknown_kind_of_object [host_object]))
- (`` (<| (case (ffi.check org/renjin/sexp/ListVector host_object)
+ (`` (<| (case (ffi.as org/renjin/sexp/ListVector host_object)
{.#Some host_object}
(<| (case (..read_variant read host_object)
{try.#Success output}
@@ -434,7 +434,7 @@
{.#None})
(~~ (template [<class> <post_processing>]
- [(case (ffi.check <class> host_object)
+ [(case (ffi.as <class> host_object)
{.#Some host_object}
(`` (|> host_object (~~ (template.splice <post_processing>))))
@@ -455,7 +455,7 @@
(def: ensure_macro
(-> Macro (Maybe org/renjin/sexp/Closure))
- (|>> (as java/lang/Object) (ffi.check org/renjin/sexp/Closure)))
+ (|>> (as java/lang/Object) (ffi.as org/renjin/sexp/Closure)))
(def: (call_macro interpreter inputs lux macro)
(-> org/renjin/script/RenjinScriptEngine (List Code) Lux org/renjin/sexp/Closure (Try (Try [Lux (List Code)])))