RUN asdl/examples/typed_arith_parse_test.py > _test/py-unit/asdl/examples/typed_arith_parse_test.py.log OK RUN asdl/format_test.py > _test/py-unit/asdl/format_test.py.log OK RUN asdl/front_end_test.py > _test/py-unit/asdl/front_end_test.py.log OK RUN asdl/gen_python_test.py > _test/py-unit/asdl/gen_python_test.py.log OK RUN asdl/target_lang_test.py > _test/py-unit/asdl/target_lang_test.py.log OK RUN benchmarks/uftrace_allocs_test.py > _test/py-unit/benchmarks/uftrace_allocs_test.py.log OK RUN build/dynamic_deps_test.py > _test/py-unit/build/dynamic_deps_test.py.log OK RUN build/ninja_lib_test.py > _test/py-unit/build/ninja_lib_test.py.log OK RUN builtin/bracket_osh_test.py > _test/py-unit/builtin/bracket_osh_test.py.log OK RUN builtin/completion_osh_test.py > _test/py-unit/builtin/completion_osh_test.py.log OK RUN builtin/func_misc_test.py > _test/py-unit/builtin/func_misc_test.py.log OK RUN builtin/misc_osh_test.py > _test/py-unit/builtin/misc_osh_test.py.log OK RUN builtin/read_osh_test.py > _test/py-unit/builtin/read_osh_test.py.log OK RUN builtin/readline_osh_test.py > _test/py-unit/builtin/readline_osh_test.py.log OK RUN builtin/trap_osh_test.py > _test/py-unit/builtin/trap_osh_test.py.log OK RUN client/py_fanos_test.py > _test/py-unit/client/py_fanos_test.py.log OK RUN core/alloc_test.py > _test/py-unit/core/alloc_test.py.log OK RUN core/comp_ui_test.py > _test/py-unit/core/comp_ui_test.py.log OK RUN core/completion_test.py > _test/py-unit/core/completion_test.py.log OK RUN core/process_test.py > _test/py-unit/core/process_test.py.log OK RUN core/pyutil_test.py > _test/py-unit/core/pyutil_test.py.log OK RUN core/state_test.py > _test/py-unit/core/state_test.py.log OK RUN core/util_test.py > _test/py-unit/core/util_test.py.log OK RUN data_lang/htm8_test.py > _test/py-unit/data_lang/htm8_test.py.log OK RUN data_lang/htm8_util_test.py > _test/py-unit/data_lang/htm8_util_test.py.log OK RUN data_lang/j8_test.py > _test/py-unit/data_lang/j8_test.py.log OK RUN data_lang/pyj8_test.py > _test/py-unit/data_lang/pyj8_test.py.log OK RUN devtools/services/zulip_test.py > _test/py-unit/devtools/services/zulip_test.py.log OK RUN display/pretty_test.py > _test/py-unit/display/pretty_test.py.log OK RUN display/ui_test.py > _test/py-unit/display/ui_test.py.log OK RUN doctools/cmark_test.py > _test/py-unit/doctools/cmark_test.py.log OK RUN doctools/help_gen_test.py > _test/py-unit/doctools/help_gen_test.py.log OK RUN doctools/html_lib_test.py > _test/py-unit/doctools/html_lib_test.py.log OK RUN doctools/html_old_test.py > _test/py-unit/doctools/html_old_test.py.log OK RUN doctools/oils_doc_test.py > _test/py-unit/doctools/oils_doc_test.py.log OK RUN doctools/spelling_test.py > _test/py-unit/doctools/spelling_test.py.log OK RUN doctools/split_doc_test.py > _test/py-unit/doctools/split_doc_test.py.log OK RUN doctools/ul_table_test.py > _test/py-unit/doctools/ul_table_test.py.log OK RUN frontend/args_test.py > _test/py-unit/frontend/args_test.py.log OK RUN frontend/id_kind_def_test.py > _test/py-unit/frontend/id_kind_def_test.py.log OK RUN frontend/lexer_def_test.py > _test/py-unit/frontend/lexer_def_test.py.log OK RUN frontend/lexer_gen_test.py > _test/py-unit/frontend/lexer_gen_test.py.log OK RUN frontend/lexer_test.py > _test/py-unit/frontend/lexer_test.py.log OK RUN frontend/match_test.py > _test/py-unit/frontend/match_test.py.log OK RUN frontend/reader_test.py > _test/py-unit/frontend/reader_test.py.log OK RUN frontend/typed_args_test.py > _test/py-unit/frontend/typed_args_test.py.log OK RUN mycpp/format_strings_test.py > _test/py-unit/mycpp/format_strings_test.py.log OK RUN mycpp/mops_test.py > _test/py-unit/mycpp/mops_test.py.log OK RUN mycpp/mylib_test.py > _test/py-unit/mycpp/mylib_test.py.log OK RUN mycpp/pass_state_test.py > _test/py-unit/mycpp/pass_state_test.py.log OK RUN osh/arith_parse_test.py > _test/py-unit/osh/arith_parse_test.py.log OK RUN osh/bool_parse_test.py > _test/py-unit/osh/bool_parse_test.py.log OK RUN osh/braces_test.py > _test/py-unit/osh/braces_test.py.log OK RUN osh/cmd_eval_test.py > _test/py-unit/osh/cmd_eval_test.py.log OK RUN osh/cmd_parse_test.py > _test/py-unit/osh/cmd_parse_test.py.log === /home/uke/oil/_test/py-unit/osh/cmd_parse_test.py.log === array=(a b c) ls ^~~~~~ "":1: Environment bindings can't contain array literals ..(command.CommandList children:[ (command.ShAssignment left: pairs:[] right: ) ) ) ] ) ] ) (command.CommandList children:[ (command.ShAssignment left: pairs:[ (InitializerWord.ArrayWord w:(w )) (InitializerWord.ArrayWord w:(w )) (InitializerWord.ArrayWord w:(w )) ] right: ) ) ) ] ) ] ) (command.CommandList children:[ (command.Sentence child:(command.ShAssignment left: pairs:[ (InitializerWord.ArrayWord w:(w )) (InitializerWord.ArrayWord w:(w )) (InitializerWord.ArrayWord w:(w )) ] right: ) ) ) ] ) terminator: ) (command.ShAssignment left: pairs:[ (InitializerWord.ArrayWord w:(w )) (InitializerWord.ArrayWord w:(w )) (InitializerWord.ArrayWord w:(w )) ] right: ) ) ) ] ) ] ) (C (w ) (w )) (command.Pipeline children:[ (C (w ) (w )) (C (w ) (w )) ] ops:[] ) (command.AndOr children:[(C (w ) (w )) (C (w ))] ops:[] ) (command.AndOr children:[ (command.Pipeline children:[ (C (w ) (w )) (C (w ) (w )) ] ops:[] ) (C (w )) ] ops:[] ) (command.Case case_kw: to_match:(case_arg.Word w:(w )) arms_start: arms:[] arms_end: ) (command.Case case_kw: to_match:(case_arg.Word w:(w )) arms_start: arms:[ (CaseArm left: pattern:(pat.Words words:[(w ) (w ) (w )] ) middle: action:[(C (w ) (w ))] right: ) ] arms_end: ) (command.Case case_kw: to_match:(case_arg.Word w:(w )) arms_start: arms:[ (CaseArm left: pattern:(pat.Words words:[(w )]) middle: action:[(C (w ) (w ))] right: ) ] arms_end: ) (command.Case case_kw: to_match:(case_arg.Word w:(w )) arms_start: arms:[ (CaseArm left: pattern:(pat.Words words:[(w )]) middle: action:[(C (w ) (w ))] right: ) (CaseArm left: pattern:(pat.Words words:[(w )]) middle: action:[(C (w ) (w ))] right: ) ] arms_end: ) (command.Case case_kw: to_match:(case_arg.Word w:(w )) arms_start: arms:[ (CaseArm left: pattern:(pat.Words words:[(w )]) middle: action:[(C (w ) (w ))] right: ) (CaseArm left: pattern:(pat.Words words:[(w )]) middle: action:[ (command.Sentence child:(C (w ) (w )) terminator: ) ] ) ] arms_end: ) (command.Case case_kw: to_match:(case_arg.Word w:(w )) arms_start: arms:[ (CaseArm left: pattern:(pat.Words words:[(w )]) middle: action:[(C (w ) (w ))] right: ) (CaseArm left: pattern:(pat.Words words:[(w )]) middle: action:[(C (w ) (w ))] ) ] arms_end: ) (command.Simple blame_tok:(Token id:Lit_Chars length:2 col:0 line:(SourceLine line_num:1 content:"ls foo" src:(source.MainFile path:"") ) ) more_env:[] words:[ (CompoundWord parts:[...0x7f798d551c20]) (CompoundWord parts:[(Token id:Lit_Chars length:3 col:3 line:...0x7f798d69df50)] ) ] is_last_cmd:F ) (ShFunction name_tok:(Token id:Lit_Chars length:3 col:0 line:(SourceLine line_num:1 content:"fun() { echo hi; }" src:(source.MainFile path:"") ) ) name:fun body:(BraceGroup left:(Token id:Lit_LBrace length:1 col:6 line:...0x7f798d69d7d0) children:[ (command.Sentence child:(command.Simple blame_tok:(Token id:Lit_Chars length:4 col:8 line:...0x7f798d69d7d0) more_env:[] words:[ (CompoundWord parts:[...0x7f798d624440]) (CompoundWord parts:[ (Token id:Lit_Chars length:2 col:13 line:...0x7f798d69d7d0) ] ) ] is_last_cmd:F ) terminator:(Token id:Op_Semi length:1 col:15 line:...0x7f798d69d7d0) ) ] right:(Token id:Lit_RBrace length:1 col:17 line:...0x7f798d69d7d0) ) code_str:"fun() { echo hi; }" ) (C (w ) (w (CommandSub left_token: child:(C (w ) (w )) right: ) (CommandSub left_token: child:(C (w ) (w )) right: ) ) ) (C (w ) (w (DQ (CommandSub left_token: child:(C (w ) (w )) right: ) (CommandSub left_token: child:(C (w ) (w )) right: ) ) ) ) (command.CommandList children:[ (command.DBracket left: expr:(bool_expr.Binary op_id:BoolBinary_gt left:(w ($ VSub_Pound)) right:(w ) ) right:.... ) ] ) (command.CommandList children:[ (command.DBracket left: expr:(bool_expr.LogicalAnd left:(bool_expr.Binary op_id:BoolBinary_gt left:(w ($ VSub_Pound)) right:(w ) ) right:(bool_expr.WordTest w:(w )) ) right: ) ] ) (command.CommandList children:[ (command.If if_kw: arms:[ (IfArm keyword:...0x7f798d5eb3d0 cond:(List_of_command (command.DBracket left: expr:(bool_expr.Binary op_id:BoolBinary_gt left:(w ($ VSub_Pound)) right:(w ) ) right: ) ) then_kw: action:[(C (w ) (w ))] then_tok:...0x7f798d5ebec0 ) ] else_action:[] fi_kw: ) ] ) (command.CommandList children:[ (command.DBracket left: expr:(bool_expr.Binary op_id:BoolBinary_EqualTilde left:(w ) right:(w ) ) right: ) ] ) (command.CommandList children:[ (command.DBracket left: expr:(bool_expr.Binary op_id:BoolBinary_EqualTilde left:(w ) right:(w (word_part.BashRegexGroup left: child:(w ) right: ) ) ) right: ) ] ) (command.CommandList children:[ (command.DParen left: child:(arith_expr.Binary op: left:(w ) right:(w ) ) right: ) ] ) (command.CommandList children:[ (command.ForEach keyword: iter_names:[i] iterable:(for_iter.Words words:[(w ) (w ) (w )] ) semi_tok: body:(command.DoGroup left: children:[(C (w ) (w ($ i)))] right: ) ) ] ) (command.CommandList children:[ (command.ForEach keyword: iter_names:[i] iterable:(for_iter.Words words:[]) semi_tok: body:(command.DoGroup left: children:[(C (w ) (w ($ i)))] right: ) ) ] ) (command.CommandList children:[ (command.ForEach keyword: iter_names:[i] iterable:(for_iter.Args) body:(command.DoGroup left: children:[ (command.Sentence child:(C (w ) (w ($ i))) terminator: ) ] right: ) ) ] ) (command.CommandList children:[ (command.ForEach keyword: iter_names:[i] iterable:(for_iter.Args) body:(command.DoGroup left: children:[(C (w ) (w ($ i)))] right: ) ) ] ) (command.CommandList children:[ (command.ForExpr keyword: init:(arith_expr.BinaryAssign op_id:Arith_Equal left: right:(w ) ) cond:(arith_expr.Binary op: left: right:(w ) ) update:(arith_expr.UnaryAssign op_id:Arith_DPlus child: ) body:(command.DoGroup left: children:[(C (w ) (w ($ i)))] . right: ) ) ] ) (command.CommandList children:[ (command.ForExpr keyword: init:(arith_expr.BinaryAssign op_id:Arith_Equal left: right:(w ) ) cond:(arith_expr.Binary op: left: right:(w ) ) update:(arith_expr.UnaryAssign op_id:Arith_DPlus child: ) body:(command.DoGroup left: children:[(C (w ) (w ($ i)))] right: ) ) ] ) (command.CommandList children:[ (command.ForExpr keyword: init:(arith_expr.EmptyZero) cond:(arith_expr.EmptyOne) update:...0x7f798db717d0 body:(command.DoGroup left: children:[(C (w ) (w ($ i)))] right: ) ) ] ) (command.CommandList children:[ (ShFunction name_tok: name:foo body:(BraceGroup left: children:[ (command.Sentence child:(C (w ) (w )) terminator: ) ] right: ) code_str:"foo() { echo hi; }" ) ] ) (command.CommandList children:[ (ShFunction name_tok: name:foo body:(command.Subshell left: child:(C (w ) (w )) right: is_last_cmd:F ) code_str:"foo() ( echo hi )" ) ] ) (command.CommandList children:[ (ShFunction name_tok: name:foo body:(command.ForEach keyword: iter_names:[i] iterable:(for_iter.Words words:[(w )]) semi_tok: body:(command.DoGroup left: children:[ (command.Sentence child:(C (w ) (w ($ i))) terminator: ) ] right: ) ) ) ] ) (command.CommandList children:[ (ShFunction keyword: name_tok: name:foo body:(BraceGroup left: children:[ (command.Sentence child:(C (w ) (w )) terminator: ) ] right: ) code_str:"function foo { echo hi; }" ) ] ) (command.CommandList children:[ (ShFunction keyword: name_tok: name:foo body:(BraceGroup left: children:[ (command.Sentence child:(C (w ) (w )) terminator: ) ] right: ) code_str:"function foo () { echo hi; }" ) ] ) (command.CommandList children:[ (ShFunction keyword: name_tok: name:foo body:(command.Subshell left: child:(C (w ) (w )) right: is_last_cmd:F ) code_str:"function foo() ( echo hi )" ) ] ) (command.CommandList children:[ (ShFunction keyword: name_tok: name:foo body:(command.ForEach keyword: iter_names:[i] iterable:(for_iter.Words words:[(w )]) semi_tok: body:(command.DoGroup left: children:[ (command.Sentence child:(C (w ) (w ($ i))) terminator: ) ] right:":1: Unexpected EOF while parsing command .Done done> ) ) ) ] ) (command.CommandList children:[ (ShFunction keyword: name_tok: name:foo body:(command.ForEach keyword: iter_names:[i] iterable:(for_iter.Words words:[(w )]) semi_tok: body:(command.DoGroup left: children:[ (command.Sentence child:(C (w ) (w ($ i))) terminator: ) ] right: ) ) ) ] ) (command.CommandList children:[ (ShFunction name_tok: name:foo body:(command.Redirect child:(BraceGroup left: children:[ (command.Sentence child:(C (w ) (w )) terminator: ) ] right: ) redirects:[ (Redir op:&"> loc:(redir_loc.Fd fd:1) arg:(w ) ) (Redir op:"> loc:(redir_loc.Fd fd:2) arg:(w ) ) ] ) ) ] ) (command.CommandList children:[ (command.If if_kw: arms:[ (IfArm keyword:...0x7f798d551590 cond:(List_of_command (command.Sentence child:(C (w )) terminator: ) ) then_kw: action:[ (command.Sentence child:(C (w ) (w )) terminator: ) ] then_tok:...0x7f798d49d600 ) ] else_action:[] fi_kw: ) ] ) (command.CommandList children:[ (command.If if_kw: arms:[ (IfArm keyword:...0x7f798d551050 cond:(List_of_command (command.Sentence child:(command.Subshell left: child:(C (w )) right: is_last_cmd:F ) terminator: ) ) then_kw: action:[ (command.Sentence child:(C (w ) (w )) terminator: ) ] then_tok:...0x7f798d551280 ) ] else_action:[] fi_kw: ) ] ) (command.CommandList children:[(C (w ))]) (C (w ) (w )) (command.Pipeline children:[ (C (w ) (w )) (C (w ) (w )) ] ops:[] ) (command.Pipeline negated: children:[ (C (w ) (w )) (C (w ) (w )) ] ops:[] ) (command.Pipeline children:[ (C (w ) (w )) (C (w ) (w )) (C (w )) ] ops:[ ] ) (command.CommandList children:[ (command.Pipeline children:[ (C (w )) (C (w )) (C (w )) ] ops:[ ] ) ] ) (command.CommandList children:[ (command.Pipeline children:[ (C (w )) (C (w )) (C (w )) ] ops:[ ] ) ] ) (command.CommandList children:[ (command.Pipeline children:[ (C (w )) (C (w )) (C (w )) ] ops:[ ] ) ] ) (command.CommandList children:[ (C (w ) (w (word_part.TildeSub left:)) (w (word_part.TildeSub left: name: user_name:root ) ) (w (word_part.TildeSub left:) ) (w (word_part.TildeSub left:) ) (w (word_part.TildeSub left: name: user_name:root ) ) (w ) ) ] ) (command.CommandList children:[ (command.WhileUntil keyword: cond:(List_of_command (command.Sentence child:(C (w )) terminator: ) ) body:(command.DoGroup left: children:[ (C (w ) (w )) (command.ControlFlow keyword:) ] right: ) ) ] ) (command.CommandList children:[ (command.WhileUntil keyword: cond:(List_of_command (command.Sentence child:(C (w )) terminator: ) ) body:(command.DoGroup left: children:[ (C (w ) (w )) (command.ControlFlow keyword:) ] right: ) ) ] ) (command.CommandList children:[ (command.WhileUntil keyword: cond:(List_of_command (C (w ))) body:(command.DoGroup left: children:[ (C (w ) (w )) (command.ControlFlow keyword:) ] right: ) ) ] ) (command.Case case_kw: to_match:(case_arg.YshExpr e:(Var x)) arms_start: arms:[] arms_end: ) (command.Case case_kw: to_match:(case_arg.YshExpr e:(Var x)) arms_start: arms:[ (CaseArm left: pattern:(pat.Else) middle: action:[ (command.Sentence child:(C (w ) (w )) terminator: ) ] right: ) ] arms_end: ) (command.Case case_kw: to_match:(case_arg.YshExpr e:(Var x)) arms_start: arms:[ (CaseArm left: pattern:(pat.YshExprs exprs:[(Const Expr_DecInt _) (Const Expr_DecInt _)]) middle: action:[ (command.Sentence child:(C (w ) (w )) terminator: ) ] right: ) ] arms_end: ) (command.Case case_kw: to_match:(case_arg.YshExpr e:(Var x)) arms_start: arms:[ (CaseArm left: pattern:(pat.Words words:[(w ) (w ) (w (SQ string))] ) middle: action:[ (command.Sentence child:(C (w ) (w )) terminator: ) ] right: ) ] arms_end: ) (command.Case case_kw: to.._match:(case_arg.YshExpr e:(Var x)) arms_start: arms:[ (CaseArm left: pattern:(Eggex left:...0x7f798d51f520 regex:(re.Repeat child:(PerlClass name:d) op:) flags:[] canonical_flags:"" ) middle: action:[ (command.Sentence child:(C (w ) (w )) terminator: ) ] right: ) (CaseArm left: pattern:(Eggex left:...0x7f798d5516e0 regex:(re.Repeat child:(PerlClass name:d) op:) flags:[] canonical_flags:"" ) middle: action:[ (command.Sentence child:(C (w ) (w )) terminator: ) ] right: ) ] arms_end: ) (command.Case case_kw: to_match:(case_arg.YshExpr e:(Var x)) arms_start: arms:[ (CaseArm left: pattern:(pat.Words words:[(w )]) middle: action:[(ExprCommand keyword: ) ] arms_end: ) (command.Case case_kw: to_match:(case_arg.YshExpr e:(Var x)) arms_start: arms:[ (CaseArm left: pattern:(Eggex left:...0x7f798d574bb0 regex:(SQ eggex) flags:[] canonical_flags:"" ) middle: action:[(ExprCommand keyword: ) ] arms_end: ) (command.Case case_kw: to_match:(case_arg.YshExpr e:(Var x)) arms_start: arms:[ (CaseArm left: pattern:(pat.YshExprs exprs:[(SQ expr)]) middle: action:[(ExprCommand keyword: ) ] arms_end: ) (command.Case case_kw: to_match:(case_arg.YshExpr e:(Var x)) arms_start: arms:[ (CaseArm left: pattern:(pat.Else) middle: action:[(ExprCommand keyword: ) ] arms_end: ) (C (w ) (w )) (command.Pipeline children:[ (C (w ) (w )) (C (w ) (w )) ] ops:[] ) (command.AndOr children:[ (command.Pipeline children:[ (C (w ) (w )) (C (w ) (w )) ] ops:[] ) (C (w )) ] ops:[] ) (command.CommandList children:[ (command.Sentence child:(command.AndOr children:[ (command.Pipeline children:[ (C (w ) (w )) (C (w ) (w )) ] ops:[] ) (C (w )) ] ops:[] ) terminator: ) (C (w ) (w )) ] ) (command.CommandList children:[(C (w ) (w ))]) (command.CommandList children:[ (command.Sentence child:(command.AndOr children:[ (command.Pipeline children:[ (C (w ) (w )) (C (w ) (w )) ] ops:[] ) (C (w )) ] ops:[] ) terminator: ) (C (w ) (w )) ] ) (command.CommandList children:[ (command. (( 1 + )) ^ "":1: Token can't be used in prefix position . A= (1 2) ^ "":1: Expected ( after = . [[ foo bar ]] ^~~ "":1: Expected ]] [[ foo -eq ]] ^ "":1: Expected ]] [[ foo$(echo <) -eq foo ]] ^ "":1: Invalid token after redirect operator . ls < ^ "":1: Invalid token after redirect operator ls < < ^ "":1: Invalid token after redirect operator echo foo$(ls <)bar ^ "":1: Invalid token after redirect operator BAD_ENV=(1 2 3) ls ^~~~~~~~ "":1: Environment bindings can't contain array literals for ((i=1; i<)); do echo $i; done ^ "":1: Token can't be used in prefix position for ((i=1; i<5; ++i)) OOPS echo $i; ERR ^~~~ "":1: Invalid word after for expression for ((i=1; i<5; ++i)); OOPS echo $i; ERR ^~~~ "":1: Expected word type Id.KW_Do, got Id.Word_Compound for $bad in 1 2; do echo hi; done ^~~~ "":1: Expected loop variable (a constant word) for foo BAD ^ "":1: Expected loop variable (a constant word) if foo; then echo hi; z ^ "":1: Expected word type Id.KW_Fi, got Id.Eof_Real foo$(invalid) () { echo hi; } ^~~ "":1: Invalid function name . foo="" echo "bar ^ "":1: Unexpected EOF reading double-quoted string that began here .. for x in 1 2 $( ^ "":1: Invalid word in for loop . for [ i = 1; i < 10; i++ ] ^ "":1: Invalid loop variable name '[' for = in a ^ "":1: Invalid loop variable name '=' . for x in 1 2 $(cat <":1: Couldn't find terminator for here doc that starts here . foo"bar" () { ^~~ "":1: Invalid function name .........F..Sentence child:(command.AndOr children:[ (command.Pipeline children:[ (C (w ) (w )) (C (w ) (w )) ] ops:[] ) (C (w ) (w )) ] ops:[] ) terminator: ) (command.AndOr children:[ (command.Pipeline children:[ (C (w ) (w )) (C (w ) (w )) ] ops:[] ) (C (w ) (w )) ] ops:[] ) ] ) (C (w )) (command.AndOr children:[(C (w )) (C (w ) (w ))] ops:[] ) (command.AndOr children:[(C (w )) (C (w ) (w ))] ops:[] ) (command.AndOr children:[(C (w )) (C (w ))] ops:[] ) (command.Pipeline children:[(C (w )) (C (w ))] ops:[] ) (command.Pipeline children:[(C (w )) (C (w ))] ops:[] ) (command.CommandList children:[ (command.Sentence child:(C (w )) terminator:) (C (w ) (w )) ] ) (command.CommandList children:[ (command.Sentence child:(C (w )) terminator:) (C (w ) (w )) ] ) (C (w )) (C (w )) (C (w )) (C (w )) (command.CommandList children:[ (command.Pipeline children:[(C (w )) (C (w ))] ops:[] ) ] ) (C (w )) (C (w ) (w (CommandSub left_token: child:(C (w ) (w (word_part.ArithSub left: anode:(arith_expr.Binary op: left:(w ) right:(arith_expr.Binary op: left:(w ) right:(w ) ) ) right: ) ) ) right: ) ) ) (command.CommandList children:[ (command.Subshell left: child:(C (w ) (w (word_part.ArithSub left: anode:(arith_expr.Binary op: left:(w ) right:(arith_expr.Binary op: left:(w ) right:(w ) ) ) right: ) ) ) right: is_last_cmd:F ) ] ) (C (w ) (w (CommandSub left_token: child:(C (w ) (w (word_part.ArithSub left: anode:(arith_expr.Binary op: left:(w ) right:(w ) ) right: ) ) ) right: ) ) ) (command.CommandList children:[ (command.Subshell left: child:(C (w ) (w (word_part.ArithSub left: anode:(arith_expr.Binary op: left:(w ) right:(w ) ) ...right: ) ) ) right: is_last_cmd:F ) ] ) (command.CommandList children:[ (C (w ) (w (CommandSub left_token: child:(command.ShAssignment left: pairs:[ (InitializerWord.ArrayWord w:(w )) (InitializerWord.ArrayWord w:(w )) (InitializerWord.ArrayWord w:(w )) ] right: ) ) ) ] ) right: ) ) ) ] ) (command.CommandList children:[ (command.Subshell left: child:(command.ShAssignment left: pairs:[ (InitializerWord.ArrayWord w:(w )) (InitializerWord.ArrayWord w:(w )) (InitializerWord.ArrayWord w:(w )) ] right: ) ) ) ] ) right: is_last_cmd:F ) ] ) (command.CommandList children:[ (C (w (CommandSub left_token: child:(command.Case case_kw: to_match:(case_arg.Word w:(w )) arms_start: arms:[ (CaseArm left: pattern:(pat.Words words:[(w )]) middle: action:[(C (w ) (w ))] right: ) ] arms_end: ) right: ) ) ) ] ) (command.CommandList children:[ (command.Subshell left: child:(command.Case case_kw: to_match:(case_arg.Word w:(w )) arms_start: arms:[ (CaseArm left: pattern:(pat.Words words:[(w )]) middle: action:[(C (w ) (w ))] right: ) ] arms_end: ) right: is_last_cmd:F ) ] ) (command.CommandList children:[ (C (w ) (w (CommandSub left_token: child:(command.Case case_kw: to_match:(case_arg.Word w:(w )) arms_start: arms:[ (CaseArm left: pattern:(pat.Words words:[(w )]) middle: action:[(C (w ) (w ))] right: ) ] arms_end: ) right: ) ) ) ] ) (command.CommandList children:[ (C (w ) (w (CommandSub .... left_token: child:(command.CommandList children:[ (command.Case case_kw: to_match:(case_arg.Word w:(w )) arms_start: arms:[ (CaseArm left: pattern:(pat.Words words:[(w )]) middle: action:[(C (w ) (w ))] right: ) ] arms_end: ) (command.Case case_kw: to_match:(case_arg.Word w:(w )) arms_start: arms:[ (CaseArm left: pattern:(pat.Words words:[(w )]) middle: action:[(C (w ) (w ))] right: ) ] arms_end: ) ] ) right: ) ) ) ] ) (C (w ) (w (DQ (CommandSub left_token: child:(C (w ) (w )) right: ) ) ) (w ) ) (command.CommandList children:[ (command.Sentence child:(C (w ) (w )) terminator: ) (command.Sentence child:(C (w ) (w (CommandSub left_token: child:(command.Case case_kw: to_match:(case_arg.Word w:(w )) arms_start: arms:[ (CaseArm left: pattern:(pat.Words words:[ (w (CommandSub left_token: child:(C (w ) (w )) right: ) ) ] ) middle: action:[ (C (w ) (w (CommandSub left_token: child:(C (w )) right: ) ) ) ] right: ) ] arms_end: ) right: ) ) ) terminator: ) (C (w ) (w )) ] ) (command.CommandList children:[ (command.Subshell left: child:(command.Case case_kw: to_match:(case_arg.Word w:(w )) arms_start: arms:[] arms_end: ) right: is_last_cmd:F ) ] ) (command.CommandList children:[ (C (w (CommandSub left_token: child:(command.ForExpr keyword: init:(arith_expr.BinaryAssign op_id:Arith_Equal left: right:(w ) ) cond:(arith_expr.Binary ..... op: left: right:(w ) ) update:(arith_expr.UnaryAssign op_id:Arith_DPlus child: ) body:(command.DoGroup left: children:[(C (w ) (w ))] right: ) ) right: ) ) ) ] ) (command.CommandList children:[ (command.Subshell left: child:(command.ForExpr keyword: init:(arith_expr.BinaryAssign op_id:Arith_Equal left: right:(w ) ) cond:(arith_expr.Binary op: left: right:(w ) ) update:(arith_expr.UnaryAssign op_id:Arith_DPlus child: ) body:(command.DoGroup left: children:[(C (w ) (w ))] right: ) ) right: is_last_cmd:F ) ] ) (C (w ) (w (word_part.ArithSub left: anode:(arith_expr.BinaryAssign op_id:Arith_Equal left:(arith_expr.Binary op: left: right:(arith_expr.Binary op: left:(w ) right:(arith_expr.Binary op: left:(w ) right:(w ) ) ) ) right: ) right: ) ) ) (C (w ) (w (CommandSub left_token: child:(C (w (CommandSub left_token: child:(C (w ) (w )) right: ) ) ) right: ) ) (w ) ) (BraceGroup left: children:[ (command.Sentence child:(C (w ) (w )) terminator: ) (command.Sentence child:(C (w ) (w )) terminator: ) ] right: ) (command.CommandList children:[ (command.Sentence child:(BraceGroup left: children:[ (command.Sentence child:(C (w ) (w )) terminator: ) (command.Sentence child:(C (w ) (w )) terminator: ) ] right: ) terminator: ) (C (w ) (w )) ] ) (command.CommandList children:[ (command.Sentence child:(command.Subshell left: child:(command.CommandList children:[ (command.Sentence child:(C (w ) (w )) terminator: ) (C (w ) (w ) (w )) ] ) right: is_last_cmd:F ) terminator: ) (C (w ) (w ) (w )) ] ) (command.CommandList children:[ (C (w ) (w (CommandSub left_token: child:(command.CommandList children:[ (command.Sentence child:(ShFunction name_tok: name:fun body:(BraceGroup left: children:[ (command.Sentence child:(C (w ) (w )) terminator: ) ] right: ) code_str:"fun() { echo hi; }" ) terminator: ) (C (w )) ] ) right: ) ) ) ] ) (command.CommandList children:[ (command.Subshell left: child:(command.CommandList children:[ (command.Sentence child:(ShFunction name_tok: name:fun body:(BraceGroup left: children:[ (command.Sentence child:(C (w ) (w )) terminator: ) ] right: ) code_str:"fun() { echo hi; }" ) terminator: ) (C (w )) ] ) right: is_last_cmd:F ) ] ) (command.CommandList children:[ (command.Sentence child:(C (w ) (w )) terminator: ) (command.Sentence child:(C (w ) (w (CommandSub left_token: child:(command.CommandList children:[ (command.Sentence child:(command.Subshell left: child:(command.CommandList children:[ (command.Sentence child:(C (w ) (w )) terminator: ) (C (w ) (w )) ] ) right: is_last_cmd:F ) terminator: ) (C (w ) (w )) ] ) right: ) ) ) terminator: ) (C (w ) (w )) ] ) (command.CommandList children:[ (C (w (CommandSub left_token: child:(command.Case case_kw: to_match:(case_arg.Word w:(w )) arms_start: arms:[ (CaseArm left: pattern:(pat.Words words:[(w )]) middle: action:[(C (w ) (w ))] right: ) ] arms_end: ) right: ) ) ) ] ) (command.CommandList children:[ (command.Subshell left: child:(command.Case case_kw: to_match:(case_arg.Word w:(w )) arms_start: arms:[ (CaseArm left: pattern:(pat.Words words:[(w )]) middle: action:[(C (w ) (w ))] right: ) ] arms_end: ) right: is_last_cmd:F ) ] ) (C..... errcmd=( "${SETUP_STATE[$err.cmd]}" ) ^ "":1: Unexpected token while parsing arithmetic: '.' ... (w ) (w (CommandSub left_token: child:(C (w ) (w )) right: ) ) (w ) ) (command.CommandList children:[ (command.Sentence child:(command.DBracket left: expr:(bool_expr.Unary op_id:BoolUnary_n child:(w (DQ (BracedVarSub left: name_tok: var_name:marks bracket_op:(bracket_op.ArrayIndex expr:(w (${ VSub_Name tag_marker) (${ VSub_Name cons_ptr) ) ) right: ) ) ) ) right: ) terminator: ) ] ) (command.CommandList children:[ (C (w ) (w (word_part.ArithSub left: anode:(w ($ foo)) right: ) ) ) ] ) (command.CommandList children:[ (command.ShAssignment left: pairs:[ (InitializerWord.ArrayWord w:(w (DQ (BracedVarSub left: name_tok: var_name:SETUP_STATE bracket_op:(bracket_op.ArrayIndex expr:(w (DQ ($ err) )) ) right: ) ) ) ) ] right: ) ) ) ] ) ] ) (command.CommandList children:[ (C (w ) (w (CommandSub left_token: child:(command.NoOp) right: ) ) ) ] ) (command.CommandList children:[ (C (w ) (w (CommandSub left_token: child:(command.NoOp) right: ) ) ) ] ) (command.CommandList children:[ (C (w ) (w ) (w (CommandSub left_token: child:(command.NoOp) right: ) ) (w ) ) ] ) (command.CommandList children:[ (command.ShAssignment left: child:(command.NoOp) right: ) (DQ ) ) ) ] ) ] ) (command.CommandList children:[ (command.If if_kw: arms:[ (IfArm keyword:...0x7f798d54aad0 cond:(List_of_command (command.Sentence child:(C (w )) terminator: ) ) then_kw: action:[ (command.Subshell left: . child:(C (w ) (w )) right: is_last_cmd:F ) ] then_tok:...0x7f798d54ac90 ) ] else_action:[] fi_kw: ) ] ) (command.CommandList children:[ (command.WhileUntil keyword: cond:(List_of_command (command.Sentence child:(C (w )) terminator: ) ) body:(command.DoGroup left: children:[ (BraceGroup left: children:[ (C (w ) (w )) (command.ControlFlow keyword:) ] right: ) ] right: ) ) ] ) (command.CommandList children:[ (command.If if_kw: arms:[ (IfArm keyword:...0x7f798d54a980 cond:(List_of_command (command.Sentence child:(C (w )) terminator: ) ) then_kw: action:[ (command.Subshell left: child:(C (w ) (w )) right: is_last_cmd:F ) ] then_tok:...0x7f798d487750 ) ] else_action:[] fi_kw: ) ] ) (command.CommandList children:[ (command.If if_kw: arms:[ (IfArm keyword:...0x7f798d487de0 cond:(List_of_command (command.Sentence child:(C (w )) terminator: ) ) then_kw: action:[ (command.If if_kw: arms:[ (IfArm keyword:...0x7f798d4f6280 cond:(List_of_command (command.Sentence child:(C (w )) terminator: ) ) then_kw: action:[(C (w ) (w ))] then_tok:...0x7f798d4f6520 ) ] else_action:[] fi_kw: ) ] then_tok:...0x7f798d4f6130 ) ] else_action:[] fi_kw: ) (C (w ) (w )) ] ) (command.CommandList children:[ (command.Subshell left: child:(command.AndOr children:[ (C (w ) (w (DQ ($ PACKDIR)))) (command.ForEach keyword: iter_names:[e] iterable:(for_iter.Words words:[(w ($ existing))]) body:(command.DoGroup left: children:[ (command.Case case_kw: to_match:(case_arg.Word w:(w (DQ ($ fullbases) )) ) arms_start: arms:[ (CaseArm left: pattern:(pat.Words words:[ (w (DQ ($ e) ) ) ] ) middle: action:[] right: ) (CaseArm left: ............ pattern:(pat.Words words:[(w )]) middle: action:[ (C (w ) (w ) (w (DQ ($ e) )) (w (DQ ($ e) )) (w (DQ ($ e) )) ) ] right: ) ] arms_end: ) ] right: ) ) ] ops:[] ) right: is_last_cmd:F ) ] ) (command.CommandList children:[ (command.Sentence child:(C (w ) (w (DQ ($ TEST_DIRECTORY)) ) ) terminator: ) ] ) (command.CommandList children:[ (C (w ) (w )) ] ) (command.CommandList children:[(C (w ) (w ))]) (command.CommandList children:[(C (w ) (w ))]) (command.Case case_kw: to_match:(case_arg.Word w:(w (DQ ($ fd) ($ command)))) arms_start: arms:[ (CaseArm left: pattern:(pat.Words words:[ (w ) (w ) ] ) middle: action:[] right: ) ] arms_end: ) (command.CommandList children:[ (command.Case case_kw: to_match:(case_arg.Word w:(w )) arms_start: arms:[ (CaseArm left: pattern:(pat.Words words:[ (w (SingleQuoted left: sval:"'" right: ) ) ] ) middle: action:[ (command.ShAssignment left: ch:"\\" ) ) (word_part.EscapedLiteral token: ch:"'" ) ) ) ] ) ] right: ) ] arms_end: ) ] ) (command.CommandList children:[ (C (w (SingleQuoted left: sval:"abc\ndef" right: ) ) ) ] ) (C (w ) (w )) (Redir op:&"> loc:(redir_loc.Fd fd:1) arg:(w )) (Redir op: loc:(redir_loc.Fd fd:0) arg:(redir_param.HereDoc here_begin:(w ) stdin_parts:[]) ) (Redir op: loc:(redir_loc.Fd fd:0) arg:(redir_param.HereDoc here_begin:(w ) stdin_parts:[]) ) (C (w )) (Redir op:"> loc:(redir_loc.Fd fd:1) arg:(w )) (Redir op: loc:(redir_loc.Fd fd:0) arg:(redir_param.HereDoc here_begin:(w ) stdin_parts:[]) ) (C (w )) (C (w )) (com...... ====================================================================== FAIL: testUnquotedHereDoc (__main__.HereDocTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/uke/oil/osh/cmd_parse_test.py", line 222, in testUnquotedHereDoc self.assertEqual(4, len(h.stdin_parts)) AssertionError: 4 != 3 ---------------------------------------------------------------------- Ran 83 tests in 0.413s FAILED (failures=1) mand.CommandList children:[ (command.ShAssignment left:"> loc:(redir_loc.Fd fd:1) arg:(w ) ) ] ) ] ) (C (w ) (w (DQ ) ) (w (DQ ) (DQ )) (w ) ) (command.CommandList children:[ (command.Simple blame_tok: more_env:[ (EnvPair left:"> loc:(redir_loc.Fd fd:1) arg:(w ) ) ] ) ] ) (command.CommandList children:[ (C (w ) (w ) (w ) (w ) ) ] ) (C (w ) (w )) (command.Simple blame_tok: more_env:[ (EnvPair left:"> loc:(redir_loc.Fd fd:1) arg:(w ) ) ] ) (command.Simple blame_tok: more_env:[ (EnvPair left:"> loc:(redir_loc.Fd fd:1) arg:(w ) ) (Redir op:"> loc:(redir_loc.Fd fd:1) arg:(w ) ) ] ) FAIL: osh/cmd_parse_test.py with code 1