soml-parser/test/cases/root/double_root.tst
Torsten Ruger ab0a94bd51 change type to class name
although int is still allowed for integers (gets replaced though)
2015-10-14 15:48:53 +03:00

35 lines
683 B
Scilab

class Object
int foo(String x)
a = 5
end
end
class Other < Object
int foo()
foo( 3 )
end
end
-- -- --
s(:statements,
s(:class, :Object,
s(:derives, nil),
s(:statements,
s(:function, :Integer,
s(:name, :foo),
s(:parameters,
s(:parameter, :String, :x)),
s(:statements,
s(:assignment,
s(:name, :a),
s(:int, 5)))))),
s(:class, :Other,
s(:derives, :Object),
s(:statements,
s(:function, :Integer,
s(:name, :foo),
s(:parameters),
s(:statements,
s(:call,
s(:name, :foo),
s(:arguments,
s(:int, 3))))))))