*** Running test-hello (nvalue.List items: [ (nvalue.Symbol s:module) (nvalue.Symbol s:hello) (nvalue.List items: [ (nvalue.Symbol s:func) (nvalue.Symbol s:main) (nvalue.List items: [ (nvalue.Symbol s:"=>") (nvalue.List items: [ (nvalue.List items: [ (nvalue.Symbol s:argv) (nvalue.List items: [(nvalue.Symbol s:List) (nvalue.Symbol s:Str)] ) ] ) ] ) (nvalue.Symbol s:Int) ] ) (nvalue.List items: [(nvalue.Symbol s:call) (nvalue.Symbol s:print) (nvalue.Str s:hello)] ) (nvalue.List items:[(nvalue.Symbol s:return) (nvalue.Int i:42)]) ] ) ] ) (Program main_module: foo modules: [ (Module name: hello defs: [ (mod_def.Func name: main sig: (Signature params:[(NameType name:argv typ:(ktype.List T:(ktype__Str)))] return_type:(ktype__Int)) statements: [(stmt.Return e:(Int i:42 loc:(Token path:path chunk:chunk start:0 length:3)))] ) ] ) ] ) #include "mycpp/runtime.h" namespace hello { int main(List* argv) { return 42; } } // namespace hello OK test-hello *** Running test-hello-cpp [1/46] make-pystub _bin/shwrap/optview_gen core/optview_gen.py frontend/option_def.py [2/46] make-pystub _bin/shwrap/consts_gen frontend/consts_gen.py _devbuild/gen/hnode_asdl.py _devbuild/gen/types_asdl.py asdl/ast.py asdl/gen_cpp.py asdl/pybase.py asdl/runtime.py asdl/util.py asdl/visitor.py frontend/builtin_def.py frontend/id_kind_def.py frontend/option_def.py mycpp/mops.py mycpp/mylib.py pylib/collections_.py [3/46] make-pystub _bin/shwrap/asdl_main asdl/asdl_main.py asdl/ast.py asdl/front_end.py asdl/gen_cpp.py asdl/gen_python.py asdl/util.py asdl/visitor.py [4/46] make-pystub _bin/shwrap/option_gen frontend/option_gen.py asdl/ast.py frontend/builtin_def.py frontend/option_def.py [5/46] make-pystub _bin/shwrap/mycpp_main mycpp/mycpp_main.py mycpp/ir_pass.py mycpp/const_pass.py mycpp/cppgen_pass.py mycpp/crash.py mycpp/debug_pass.py mycpp/control_flow_pass.py mycpp/format_strings.py mycpp/pass_state.py mycpp/util.py mycpp/visitor.py [6/46] optview_gen > _gen/core/optview.h [7/46] consts_gen cpp _gen/frontend/id_kind.asdl [8/46] asdl_main cpp --no-pretty-print-methods asdl/hnode.asdl _gen/asdl/hnode.asdl _gen/asdl/hnode.asdl_debug.py [9/46] asdl_main cpp core/value.asdl _gen/core/value.asdl _gen/core/value.asdl_debug.py [10/46] cxx opt '' mycpp/bump_leak_heap.cc _build/obj/cxx-opt/mycpp/bump_leak_heap.o [11/46] asdl_main cpp core/runtime.asdl _gen/core/runtime.asdl _gen/core/runtime.asdl_debug.py [12/46] consts_gen cpp-consts _gen/frontend/consts [13/46] consts_gen cpp _gen/frontend/option.asdl [14/46] asdl_main cpp --no-pretty-print-methods frontend/types.asdl _gen/frontend/types.asdl _gen/frontend/types.asdl_debug.py [15/46] asdl_main cpp data_lang/nil8.asdl _gen/data_lang/nil8.asdl _gen/data_lang/nil8.asdl_debug.py [16/46] asdl_main cpp yaks/yaks.asdl _gen/yaks/yaks.asdl _gen/yaks/yaks.asdl_debug.py [17/46] asdl_main cpp frontend/syntax.asdl _gen/frontend/syntax.asdl _gen/frontend/syntax.asdl_debug.py [18/46] cxx opt '' mycpp/gc_mops.cc _build/obj/cxx-opt/mycpp/gc_mops.o [19/46] cxx opt '' _gen/frontend/id_kind.asdl.cc _build/obj/cxx-opt/_gen/frontend/id_kind.asdl.o [20/46] cxx opt '' mycpp/gc_builtins.cc _build/obj/cxx-opt/mycpp/gc_builtins.o [21/46] cxx opt '' mycpp/gc_mylib.cc _build/obj/cxx-opt/mycpp/gc_mylib.o [22/46] cxx opt '' cpp/data_lang.cc _build/obj/cxx-opt/cpp/data_lang.o [23/46] cxx opt '' mycpp/hash.cc _build/obj/cxx-opt/mycpp/hash.o [24/46] cxx opt '' _gen/core/runtime.asdl.cc _build/obj/cxx-opt/_gen/core/runtime.asdl.o [25/46] cxx asan '' mycpp/bump_leak_heap.cc _build/obj/cxx-asan/mycpp/bump_leak_heap.o [26/46] cxx opt '' mycpp/mark_sweep_heap.cc _build/obj/cxx-opt/mycpp/mark_sweep_heap.o [27/46] cxx opt '' _gen/core/value.asdl.cc _build/obj/cxx-opt/_gen/core/value.asdl.o [28/46] cxx asan '' mycpp/gc_mops.cc _build/obj/cxx-asan/mycpp/gc_mops.o [29/46] cxx asan '' mycpp/gc_builtins.cc _build/obj/cxx-asan/mycpp/gc_builtins.o [30/46] cxx asan '' mycpp/hash.cc _build/obj/cxx-asan/mycpp/hash.o [31/46] cxx asan '' mycpp/gc_mylib.cc _build/obj/cxx-asan/mycpp/gc_mylib.o [32/46] cxx asan '' mycpp/mark_sweep_heap.cc _build/obj/cxx-asan/mycpp/mark_sweep_heap.o [33/46] cxx opt '' _gen/data_lang/nil8.asdl.cc _build/obj/cxx-opt/_gen/data_lang/nil8.asdl.o [34/46] cxx opt '' cpp/frontend_match.cc _build/obj/cxx-opt/cpp/frontend_match.o [35/46] cxx opt '' _gen/frontend/consts.cc _build/obj/cxx-opt/_gen/frontend/consts.o [36/46] cxx opt '' _gen/frontend/syntax.asdl.cc _build/obj/cxx-opt/_gen/frontend/syntax.asdl.o [37/46] cxx asan '' mycpp/gc_str.cc _build/obj/cxx-asan/mycpp/gc_str.o [38/46] cxx opt '' mycpp/gc_str.cc _build/obj/cxx-opt/mycpp/gc_str.o [39/46] cxx opt '' _gen/yaks/yaks.asdl.cc _build/obj/cxx-opt/_gen/yaks/yaks.asdl.o [40/46] gen-oils-for-unix yaks_main _gen/yaks/yaks_main.mycpp yaks/preamble.h asdl/format.py asdl/runtime.py core/ansi.py core/error.py core/num.py data_lang/j8.py data_lang/j8_lite.py pylib/cgi.py yaks/gen_cpp.py yaks/transform.py yaks/yaks_main.py mycpp: LOADING asdl/format.py asdl/runtime.py core/ansi.py core/error.py core/num.py data_lang/j8.py data_lang/j8_lite.py pylib/cgi.py yaks/gen_cpp.py yaks/transform.py yaks/yaks_main.py mycpp pass: IR mycpp pass: CONST mycpp pass: FORWARD DECL mycpp pass: PROTOTYPES mycpp pass: CONTROL FLOW mycpp pass: IMPL [41/46] cxx opt '' _gen/yaks/yaks_main.mycpp.cc _build/obj/cxx-opt/_gen/yaks/yaks_main.mycpp.o _gen/yaks/yaks_main.mycpp.cc: In member function 'void format::_PrettyPrinter::PrintNode(hnode_asdl::hnode_t*, format::ColorOutput*, int)': _gen/yaks/yaks_main.mycpp.cc:1354:24: warning: unused variable 'node' [-Wunused-variable] hnode::External* node = static_cast(UP_node); ^~~~ _gen/yaks/yaks_main.mycpp.cc: In function 'bool format::_TrySingleLine(hnode_asdl::hnode_t*, format::ColorOutput*, int)': _gen/yaks/yaks_main.mycpp.cc:1442:24: warning: unused variable 'node' [-Wunused-variable] hnode::External* node = static_cast(UP_node); ^~~~ [42/46] LINK cxx opt '' _bin/cxx-opt/yaks/yaks_main.mycpp _build/obj/cxx-opt/_gen/yaks/yaks_main.mycpp.o _build/obj/cxx-opt/_gen/core/runtime.asdl.o _build/obj/cxx-opt/_gen/core/value.asdl.o _build/obj/cxx-opt/cpp/data_lang.o _build/obj/cxx-opt/cpp/frontend_match.o _build/obj/cxx-opt/_gen/data_lang/nil8.asdl.o _build/obj/cxx-opt/_gen/frontend/consts.o _build/obj/cxx-opt/_gen/frontend/id_kind.asdl.o _build/obj/cxx-opt/_gen/frontend/syntax.asdl.o _build/obj/cxx-opt/mycpp/bump_leak_heap.o _build/obj/cxx-opt/mycpp/gc_builtins.o _build/obj/cxx-opt/mycpp/gc_mops.o _build/obj/cxx-opt/mycpp/gc_mylib.o _build/obj/cxx-opt/mycpp/gc_str.o _build/obj/cxx-opt/mycpp/hash.o _build/obj/cxx-opt/mycpp/mark_sweep_heap.o _build/obj/cxx-opt/_gen/yaks/yaks.asdl.o [43/46] yaks cpp yaks/examples/hello.yaks > _gen/yaks/examples/hello_raw.yaks.cc (nvalue.List items: [ (nvalue.Symbol s:module) (nvalue.Symbol s:hello) (nvalue.List items: [ (nvalue.Symbol s:func) (nvalue.Symbol s:main) (nvalue.List items: [ (nvalue.Symbol s:"=>") (nvalue.List items: [ (nvalue.List items: [ (nvalue.Symbol s:argv) (nvalue.List items: [(nvalue.Symbol s:List) (nvalue.Symbol s:Str)] ) ] ) ] ) (nvalue.Symbol s:Int) ] ) (nvalue.List items: [(nvalue.Symbol s:call) (nvalue.Symbol s:print) (nvalue.Str s:hello)] ) (nvalue.List items:[(nvalue.Symbol s:return) (nvalue.Int i:42)]) ] ) ] ) (Program main_module: foo modules: [ (Module name: hello defs: [ (mod_def.Func name: main sig: (Signature params: [(NameType name:argv typ:(ktype.List T:(ktype.Str)))] return_type: ...0x3ffffffc ) statements: [(stmt.Return e:(Int i:42 loc:(Token path:path chunk:chunk start:0 length:3)))] ) ] ) ] ) [44/46] wrap-cc _gen/yaks/examples/hello.yaks.cc yaks hello _gen/yaks/examples/hello_raw.yaks.cc "" _gen/yaks/examples/hello.yaks.cc [45/46] cxx asan '' _gen/yaks/examples/hello.yaks.cc _build/obj/cxx-asan/_gen/yaks/examples/hello.yaks.o [46/46] LINK cxx asan '' _bin/cxx-asan/yaks/examples/hello.yaks _build/obj/cxx-asan/_gen/yaks/examples/hello.yaks.o _build/obj/cxx-asan/mycpp/bump_leak_heap.o _build/obj/cxx-asan/mycpp/gc_builtins.o _build/obj/cxx-asan/mycpp/gc_mops.o _build/obj/cxx-asan/mycpp/gc_mylib.o _build/obj/cxx-asan/mycpp/gc_str.o _build/obj/cxx-asan/mycpp/hash.o _build/obj/cxx-asan/mycpp/mark_sweep_heap.o + set +o errexit + _bin/cxx-asan/yaks/examples/hello.yaks + local status=42 + set -o errexit + echo status=42 status=42 OK test-hello-cpp *** Running test-syntax-errors (print "hi") (nvalue.List items:[(nvalue.Symbol s:print) (nvalue.Str s:hi)]) Traceback (most recent call last): File "yaks/yaks_main.py", line 151, in main(sys.argv) File "yaks/yaks_main.py", line 123, in main prog = transform.Transform(nval) File "/home/uke/oil/yaks/transform.py", line 248, in Transform module = TransformModule(mod_n) File "/home/uke/oil/yaks/transform.py", line 208, in TransformModule mod_name = MustBeSymbol(mod_n[1]) File "/home/uke/oil/yaks/transform.py", line 22, in MustBeSymbol raise AssertionError('Expected Symbol, got %s' % nval) AssertionError: Expected Symbol, got (nvalue.Str s:hi) + (nvalue.Symbol s:"+") Traceback (most recent call last): File "yaks/yaks_main.py", line 151, in main(sys.argv) File "yaks/yaks_main.py", line 123, in main prog = transform.Transform(nval) File "/home/uke/oil/yaks/transform.py", line 247, in Transform mod_n = MustBeList(nval) File "/home/uke/oil/yaks/transform.py", line 29, in MustBeList raise AssertionError('Expected List, got %s' % nval) AssertionError: Expected List, got (nvalue.Symbol s:"+") (print Unexpected EOF while parsing J8 (line 2, offset 7-7: 'int\n') (print)oops Unexpected trailing input (line 1, offset 7-11: 'int)oops\n') OK test-syntax-errors yaks/TEST.sh: 3 tests passed. yaks/yaks.asdl -> (asdl_main) -> _devbuild/gen/yaks_asdl.py Success: no issues found in 1 source file