change syntax for javascript code literals

This commit is contained in:
2024-11-25 21:53:23 -08:00
parent 07cbeec6cc
commit e265248b11
21 changed files with 140 additions and 287 deletions

View File

@@ -25,9 +25,9 @@ max x y = case x < y of
True => y
False => x
pfunc repr : {a : U} -> a -> String := "(a,o) => ''+o"
pfunc jrepr : {a : U} -> a -> String := "(a,o) => JSON.stringify(o, null, ' ')"
pfunc toInt : String -> Int := "s => Number(s)"
pfunc repr : {a : U} -> a -> String := `(a,o) => ''+o`
pfunc jrepr : {a : U} -> a -> String := `(a,o) => JSON.stringify(o, null, ' ')`
pfunc toInt : String -> Int := `s => Number(s)`
mapM : {a b c : U} -> (a -> Either b c) -> List a -> Either b (List c)
mapM f Nil = Right Nil