(.module: lux (lux (control monad) (data text/format) [macro "macro/" Monad]) (luxc ["&" lang] (lang [".L" host] (host ["$" jvm] (jvm ["$i" inst] ["$t" type])) ["la" analysis] ["ls" synthesis])) (// [".T" common])) (def: #export (translate-bool value) (-> Bool (Meta $.Inst)) (macro/wrap ($i.GETSTATIC "java.lang.Boolean" (if value "TRUE" "FALSE") ($t.class "java.lang.Boolean" (list))))) (do-template [ ] [(def: #export ( value) (-> (Meta $.Inst)) (macro/wrap (|>> ( value) )))] [translate-i64 Int $i.long ($i.wrap #$.Long)] [translate-f64 Frac $i.double ($i.wrap #$.Double)] [translate-text Text $i.string id] )