@@ -403,7 +403,7 @@ def make_call(id_: str, lineno: int, args: symbols.ARGLIST):
403403 offset = make_typecast (TYPE .uinteger ,
404404 make_number (arr .offset , lineno = lineno ),
405405 lineno )
406- arr .appendChild (offset )
406+ arr .append_child (offset )
407407 return arr
408408
409409 if entry .class_ == CLASS .var : # An already declared/used string var
@@ -532,7 +532,7 @@ def p_start(p):
532532
533533 if not is_null (ast ):
534534 if isinstance (ast , symbols .BLOCK ) and not is_ender (ast [- 1 ]):
535- ast .appendChild (__end )
535+ ast .append_child (__end )
536536 else :
537537 ast = __end
538538
@@ -554,11 +554,11 @@ def p_start(p):
554554
555555 # Appends variable declarations at the end.
556556 for var in SYMBOL_TABLE .vars_ :
557- data_ast .appendChild (make_var_declaration (var ))
557+ data_ast .append_child (make_var_declaration (var ))
558558
559559 # Appends arrays declarations at the end.
560560 for var in SYMBOL_TABLE .arrays :
561- data_ast .appendChild (make_array_declaration (var ))
561+ data_ast .append_child (make_array_declaration (var ))
562562
563563
564564def p_program_program_line (p ):
@@ -1514,7 +1514,7 @@ def p_if_then_part(p):
15141514def p_if_inline (p ):
15151515 """ statement : if_inline else_part_inline
15161516 """
1517- p [1 ].appendChild (make_block (p [2 ][0 ], p [2 ][1 ]))
1517+ p [1 ].append_child (make_block (p [2 ][0 ], p [2 ][1 ]))
15181518 p [0 ] = p [1 ]
15191519
15201520
@@ -1544,7 +1544,7 @@ def p_for_sentence(p):
15441544 p [0 ] = p [1 ]
15451545 if is_null (p [0 ]):
15461546 return
1547- p [1 ].appendChild (make_block (p [2 ], p [3 ]))
1547+ p [1 ].append_child (make_block (p [2 ], p [3 ]))
15481548 gl .LOOPS .pop ()
15491549
15501550
@@ -2020,18 +2020,18 @@ def p_print_list(p):
20202020 p [0 ].eol = (p [3 ] is not None )
20212021
20222022 if p [3 ] is not None :
2023- p [0 ].appendChild (p [3 ])
2023+ p [0 ].append_child (p [3 ])
20242024
20252025
20262026def p_print_list_comma (p ):
20272027 """ print_list : print_list COMMA print_elem
20282028 """
20292029 p [0 ] = p [1 ]
20302030 p [0 ].eol = (p [3 ] is not None )
2031- p [0 ].appendChild (make_sentence (p .lineno (2 ), 'PRINT_COMMA' ))
2031+ p [0 ].append_child (make_sentence (p .lineno (2 ), 'PRINT_COMMA' ))
20322032
20332033 if p [3 ] is not None :
2034- p [0 ].appendChild (p [3 ])
2034+ p [0 ].append_child (p [3 ])
20352035
20362036
20372037def p_print_list_at (p ):
@@ -2943,7 +2943,7 @@ def p_function_header_pre(p):
29432943 forwarded = p [1 ].entry .forwarded
29442944
29452945 p [0 ] = p [1 ]
2946- p [0 ].appendChild (p [2 ])
2946+ p [0 ].append_child (p [2 ])
29472947 p [0 ].params_size = p [2 ].size
29482948 lineno = p .lineno (3 )
29492949
0 commit comments