add operators
This commit is contained in:
15
newt/tutorial.newt
Normal file
15
newt/tutorial.newt
Normal file
@@ -0,0 +1,15 @@
|
||||
-- Files begin with a module declaration, modules not implemented yet
|
||||
module Tutorial
|
||||
|
||||
|
||||
-- import Prelude not implemented yet
|
||||
|
||||
-- declare a primitive type
|
||||
ptype Int
|
||||
|
||||
-- declare a more complex primitive type
|
||||
ptype Array : U -> U
|
||||
|
||||
-- declare a primitive function
|
||||
pfunc alength : {a : U} -> Array a -> Int := "(x) => x.length"
|
||||
|
||||
Reference in New Issue
Block a user