soml-parser/test/cases/module_def/module_ops.tst

21 lines
412 B
Scilab
Raw Normal View History

module Opers
int foo(int x)
int abba = 5
return abba + 5
end
end
-- -- --
s(:list, [s(:module, "Opers", [s(:function, :int,
s(:name, "foo"),
s(:parameters,
s(:field, :int, :x)),
s(:expressions,
s(:name, "int"),
s(:assign,
s(:name, "abba"),
s(:int, 5)),
s(:return,
s(:operator, "+",
s(:name, "abba"),
s(:int, 5)))))])])