1 # Production AST nodes full definition.
2 # This file was generated by SableCC (http://www.sablecc.org/).
6 intrude import parser_nodes
9 # Parent of the node in the AST
10 readable writable attr _parent
: PNode
12 # Remove a child from the AST
13 meth remove_child
(child
: PNode)
15 replace_child
(child
, null)
18 # Replace a child with an other node in the AST
19 meth replace_child
(old_child
: PNode, new_child
: PNode) is abstract
21 # Replace itself with an other node in the AST
22 meth replace_with
(node
: PNode)
24 if (_parent
!= null) then
25 _parent
.replace_child
(self, node
)
29 # Visit all nodes in order.
30 # Thus, call "v.visit(e)" for each node e
31 meth visit_all
(v
: Visitor) is abstract
33 # Visit all nodes in reverse order.
34 # Thus, call "v.visit(e)" for each node e starting from the last child
35 meth visit_all_reverse
(v
: Visitor) is abstract
37 # Give a human readable location of the node.
38 meth locate
: String is abstract
40 # Return only the line number of the node
41 meth line_number
: Int is abstract
43 # Debug method: output a message prefixed with the location.
44 meth printl
(str
: String)
46 print
("{locate}: {str}\n")
51 redef meth visit_all
(v
: Visitor) do end
52 redef meth visit_all_reverse
(v
: Visitor) do end
53 redef meth replace_child
(old_child
: PNode, new_child
: PNode) do end
55 redef meth locate
: String
57 return "{filename}:{line},{pos}"
60 redef meth line_number
do return line
64 # The first token of the production node
65 readable writable attr _first_token
: Token
67 # The last token of the production node
68 readable writable attr _last_token
: Token
70 redef meth locate
: String
72 if first_token
== null then
75 var lastpos
= last_token
.pos
+ last_token
.text
.length
- 1
76 if first_token
.line
== last_token
.line
then
77 return "{first_token.locate}--{lastpos}"
79 return "{first_token.locate}--{last_token.line}:{lastpos}"
83 redef meth replace_with
(n
: PNode)
87 n
.first_token
= first_token
88 n
.last_token
= last_token
91 redef meth line_number
93 if first_token
!= null then
94 return first_token
.line
101 # Abstract standard visitor
103 # Ask the visitor to visit a given node.
104 # Usually automatically called by visit_all* methods.
105 # Concrete visitors should redefine this method.
106 meth visit
(e
: PNode) is abstract
110 redef meth n_packagedecl
=(n
: PPackagedecl)
118 private init empty_init
do end
121 n_packagedecl
: PPackagedecl ,
122 n_imports
: Array[Object] , # Should be Array[PImport]
123 n_classdefs
: Array[Object] # Should be Array[PClassdef]
126 _n_packagedecl
= n_packagedecl
127 if n_packagedecl
!= null then
128 n_packagedecl
.parent
= self
130 _n_imports
= new List[PImport]
131 for n
in n_imports
do
136 _n_classdefs
= new List[PClassdef]
137 for n
in n_classdefs
do
138 assert n
isa PClassdef
144 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
146 assert old_child
!= null
147 if _n_packagedecl
== old_child
then
148 if new_child
!= null then
149 new_child
.parent
= self
150 assert new_child
isa PPackagedecl
151 _n_packagedecl
= new_child
153 _n_packagedecl
= null
157 for i
in [0.._n_imports
.length
[ do
158 if _n_imports
[i
] == old_child
then
159 if new_child
!= null then
160 assert new_child
isa PImport
161 _n_imports
[i
] = new_child
162 new_child
.parent
= self
164 _n_imports
.remove_at
(i
)
169 for i
in [0.._n_classdefs
.length
[ do
170 if _n_classdefs
[i
] == old_child
then
171 if new_child
!= null then
172 assert new_child
isa PClassdef
173 _n_classdefs
[i
] = new_child
174 new_child
.parent
= self
176 _n_classdefs
.remove_at
(i
)
183 redef meth visit_all
(v
: Visitor)
185 if _n_packagedecl
!= null then
186 v
.visit
(_n_packagedecl
)
188 for n
in _n_imports
do
191 for n
in _n_classdefs
do
196 redef meth visit_all_reverse
(v
: Visitor)
198 if _n_packagedecl
!= null then
199 v
.visit
(_n_packagedecl
)
202 var i
= _n_imports
.length
204 v
.visit
(_n_imports
[i
])
209 var i
= _n_classdefs
.length
211 v
.visit
(_n_classdefs
[i
])
217 redef class APackagedecl
218 redef meth n_doc
=(n
: PDoc)
225 redef meth n_kwpackage
=(n
: TKwpackage)
232 redef meth n_id
=(n
: TId)
240 private init empty_init
do end
242 init init_apackagedecl
(
244 n_kwpackage
: TKwpackage ,
249 if n_doc
!= null then
252 _n_kwpackage
= n_kwpackage
253 if n_kwpackage
!= null then
254 n_kwpackage
.parent
= self
262 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
264 assert old_child
!= null
265 if _n_doc
== old_child
then
266 if new_child
!= null then
267 new_child
.parent
= self
268 assert new_child
isa PDoc
275 if _n_kwpackage
== old_child
then
276 if new_child
!= null then
277 new_child
.parent
= self
278 assert new_child
isa TKwpackage
279 _n_kwpackage
= new_child
285 if _n_id
== old_child
then
286 if new_child
!= null then
287 new_child
.parent
= self
288 assert new_child
isa TId
297 redef meth visit_all
(v
: Visitor)
299 if _n_doc
!= null then
302 if _n_kwpackage
!= null then
303 v
.visit
(_n_kwpackage
)
305 if _n_id
!= null then
310 redef meth visit_all_reverse
(v
: Visitor)
312 if _n_doc
!= null then
315 if _n_kwpackage
!= null then
316 v
.visit
(_n_kwpackage
)
318 if _n_id
!= null then
324 redef meth n_visibility
=(n
: PVisibility)
331 redef meth n_kwimport
=(n
: TKwimport)
338 redef meth n_id
=(n
: TId)
346 private init empty_init
do end
349 n_visibility
: PVisibility ,
350 n_kwimport
: TKwimport ,
354 _n_visibility
= n_visibility
355 if n_visibility
!= null then
356 n_visibility
.parent
= self
358 _n_kwimport
= n_kwimport
359 if n_kwimport
!= null then
360 n_kwimport
.parent
= self
368 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
370 assert old_child
!= null
371 if _n_visibility
== old_child
then
372 if new_child
!= null then
373 new_child
.parent
= self
374 assert new_child
isa PVisibility
375 _n_visibility
= new_child
381 if _n_kwimport
== old_child
then
382 if new_child
!= null then
383 new_child
.parent
= self
384 assert new_child
isa TKwimport
385 _n_kwimport
= new_child
391 if _n_id
== old_child
then
392 if new_child
!= null then
393 new_child
.parent
= self
394 assert new_child
isa TId
403 redef meth visit_all
(v
: Visitor)
405 if _n_visibility
!= null then
406 v
.visit
(_n_visibility
)
408 if _n_kwimport
!= null then
411 if _n_id
!= null then
416 redef meth visit_all_reverse
(v
: Visitor)
418 if _n_visibility
!= null then
419 v
.visit
(_n_visibility
)
421 if _n_kwimport
!= null then
424 if _n_id
!= null then
429 redef class ANoImport
430 redef meth n_visibility
=(n
: PVisibility)
437 redef meth n_kwimport
=(n
: TKwimport)
444 redef meth n_kwend
=(n
: TKwend)
452 private init empty_init
do end
454 init init_anoimport
(
455 n_visibility
: PVisibility ,
456 n_kwimport
: TKwimport ,
460 _n_visibility
= n_visibility
461 if n_visibility
!= null then
462 n_visibility
.parent
= self
464 _n_kwimport
= n_kwimport
465 if n_kwimport
!= null then
466 n_kwimport
.parent
= self
469 if n_kwend
!= null then
470 n_kwend
.parent
= self
474 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
476 assert old_child
!= null
477 if _n_visibility
== old_child
then
478 if new_child
!= null then
479 new_child
.parent
= self
480 assert new_child
isa PVisibility
481 _n_visibility
= new_child
487 if _n_kwimport
== old_child
then
488 if new_child
!= null then
489 new_child
.parent
= self
490 assert new_child
isa TKwimport
491 _n_kwimport
= new_child
497 if _n_kwend
== old_child
then
498 if new_child
!= null then
499 new_child
.parent
= self
500 assert new_child
isa TKwend
509 redef meth visit_all
(v
: Visitor)
511 if _n_visibility
!= null then
512 v
.visit
(_n_visibility
)
514 if _n_kwimport
!= null then
517 if _n_kwend
!= null then
522 redef meth visit_all_reverse
(v
: Visitor)
524 if _n_visibility
!= null then
525 v
.visit
(_n_visibility
)
527 if _n_kwimport
!= null then
530 if _n_kwend
!= null then
535 redef class APublicVisibility
537 private init empty_init
do end
539 init init_apublicvisibility
543 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
545 assert old_child
!= null
548 redef meth visit_all
(v
: Visitor)
552 redef meth visit_all_reverse
(v
: Visitor)
556 redef class APrivateVisibility
557 redef meth n_kwprivate
=(n
: TKwprivate)
565 private init empty_init
do end
567 init init_aprivatevisibility
(
568 n_kwprivate
: TKwprivate
571 _n_kwprivate
= n_kwprivate
572 if n_kwprivate
!= null then
573 n_kwprivate
.parent
= self
577 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
579 assert old_child
!= null
580 if _n_kwprivate
== old_child
then
581 if new_child
!= null then
582 new_child
.parent
= self
583 assert new_child
isa TKwprivate
584 _n_kwprivate
= new_child
592 redef meth visit_all
(v
: Visitor)
594 if _n_kwprivate
!= null then
595 v
.visit
(_n_kwprivate
)
599 redef meth visit_all_reverse
(v
: Visitor)
601 if _n_kwprivate
!= null then
602 v
.visit
(_n_kwprivate
)
606 redef class AProtectedVisibility
607 redef meth n_kwprotected
=(n
: TKwprotected)
615 private init empty_init
do end
617 init init_aprotectedvisibility
(
618 n_kwprotected
: TKwprotected
621 _n_kwprotected
= n_kwprotected
622 if n_kwprotected
!= null then
623 n_kwprotected
.parent
= self
627 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
629 assert old_child
!= null
630 if _n_kwprotected
== old_child
then
631 if new_child
!= null then
632 new_child
.parent
= self
633 assert new_child
isa TKwprotected
634 _n_kwprotected
= new_child
636 _n_kwprotected
= null
642 redef meth visit_all
(v
: Visitor)
644 if _n_kwprotected
!= null then
645 v
.visit
(_n_kwprotected
)
649 redef meth visit_all_reverse
(v
: Visitor)
651 if _n_kwprotected
!= null then
652 v
.visit
(_n_kwprotected
)
656 redef class AIntrudeVisibility
657 redef meth n_kwintrude
=(n
: TKwintrude)
665 private init empty_init
do end
667 init init_aintrudevisibility
(
668 n_kwintrude
: TKwintrude
671 _n_kwintrude
= n_kwintrude
672 if n_kwintrude
!= null then
673 n_kwintrude
.parent
= self
677 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
679 assert old_child
!= null
680 if _n_kwintrude
== old_child
then
681 if new_child
!= null then
682 new_child
.parent
= self
683 assert new_child
isa TKwintrude
684 _n_kwintrude
= new_child
692 redef meth visit_all
(v
: Visitor)
694 if _n_kwintrude
!= null then
695 v
.visit
(_n_kwintrude
)
699 redef meth visit_all_reverse
(v
: Visitor)
701 if _n_kwintrude
!= null then
702 v
.visit
(_n_kwintrude
)
706 redef class AClassdef
707 redef meth n_doc
=(n
: PDoc)
714 redef meth n_kwredef
=(n
: TKwredef)
721 redef meth n_visibility
=(n
: PVisibility)
728 redef meth n_classkind
=(n
: PClasskind)
735 redef meth n_id
=(n
: TClassid)
743 private init empty_init
do end
745 init init_aclassdef
(
747 n_kwredef
: TKwredef ,
748 n_visibility
: PVisibility ,
749 n_classkind
: PClasskind ,
751 n_formaldefs
: Array[Object] , # Should be Array[PFormaldef]
752 n_superclasses
: Array[Object] , # Should be Array[PSuperclass]
753 n_propdefs
: Array[Object] # Should be Array[PPropdef]
757 if n_doc
!= null then
760 _n_kwredef
= n_kwredef
761 if n_kwredef
!= null then
762 n_kwredef
.parent
= self
764 _n_visibility
= n_visibility
765 if n_visibility
!= null then
766 n_visibility
.parent
= self
768 _n_classkind
= n_classkind
769 if n_classkind
!= null then
770 n_classkind
.parent
= self
776 _n_formaldefs
= new List[PFormaldef]
777 for n
in n_formaldefs
do
778 assert n
isa PFormaldef
782 _n_superclasses
= new List[PSuperclass]
783 for n
in n_superclasses
do
784 assert n
isa PSuperclass
785 _n_superclasses
.add
(n
)
788 _n_propdefs
= new List[PPropdef]
789 for n
in n_propdefs
do
790 assert n
isa PPropdef
796 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
798 assert old_child
!= null
799 if _n_doc
== old_child
then
800 if new_child
!= null then
801 new_child
.parent
= self
802 assert new_child
isa PDoc
809 if _n_kwredef
== old_child
then
810 if new_child
!= null then
811 new_child
.parent
= self
812 assert new_child
isa TKwredef
813 _n_kwredef
= new_child
819 if _n_visibility
== old_child
then
820 if new_child
!= null then
821 new_child
.parent
= self
822 assert new_child
isa PVisibility
823 _n_visibility
= new_child
829 if _n_classkind
== old_child
then
830 if new_child
!= null then
831 new_child
.parent
= self
832 assert new_child
isa PClasskind
833 _n_classkind
= new_child
839 if _n_id
== old_child
then
840 if new_child
!= null then
841 new_child
.parent
= self
842 assert new_child
isa TClassid
849 for i
in [0.._n_formaldefs
.length
[ do
850 if _n_formaldefs
[i
] == old_child
then
851 if new_child
!= null then
852 assert new_child
isa PFormaldef
853 _n_formaldefs
[i
] = new_child
854 new_child
.parent
= self
856 _n_formaldefs
.remove_at
(i
)
861 for i
in [0.._n_superclasses
.length
[ do
862 if _n_superclasses
[i
] == old_child
then
863 if new_child
!= null then
864 assert new_child
isa PSuperclass
865 _n_superclasses
[i
] = new_child
866 new_child
.parent
= self
868 _n_superclasses
.remove_at
(i
)
873 for i
in [0.._n_propdefs
.length
[ do
874 if _n_propdefs
[i
] == old_child
then
875 if new_child
!= null then
876 assert new_child
isa PPropdef
877 _n_propdefs
[i
] = new_child
878 new_child
.parent
= self
880 _n_propdefs
.remove_at
(i
)
887 redef meth visit_all
(v
: Visitor)
889 if _n_doc
!= null then
892 if _n_kwredef
!= null then
895 if _n_visibility
!= null then
896 v
.visit
(_n_visibility
)
898 if _n_classkind
!= null then
899 v
.visit
(_n_classkind
)
901 if _n_id
!= null then
904 for n
in _n_formaldefs
do
907 for n
in _n_superclasses
do
910 for n
in _n_propdefs
do
915 redef meth visit_all_reverse
(v
: Visitor)
917 if _n_doc
!= null then
920 if _n_kwredef
!= null then
923 if _n_visibility
!= null then
924 v
.visit
(_n_visibility
)
926 if _n_classkind
!= null then
927 v
.visit
(_n_classkind
)
929 if _n_id
!= null then
933 var i
= _n_formaldefs
.length
935 v
.visit
(_n_formaldefs
[i
])
940 var i
= _n_superclasses
.length
942 v
.visit
(_n_superclasses
[i
])
947 var i
= _n_propdefs
.length
949 v
.visit
(_n_propdefs
[i
])
955 redef class ATopClassdef
957 private init empty_init
do end
959 init init_atopclassdef
(
960 n_propdefs
: Array[Object] # Should be Array[PPropdef]
963 _n_propdefs
= new List[PPropdef]
964 for n
in n_propdefs
do
965 assert n
isa PPropdef
971 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
973 assert old_child
!= null
974 for i
in [0.._n_propdefs
.length
[ do
975 if _n_propdefs
[i
] == old_child
then
976 if new_child
!= null then
977 assert new_child
isa PPropdef
978 _n_propdefs
[i
] = new_child
979 new_child
.parent
= self
981 _n_propdefs
.remove_at
(i
)
988 redef meth visit_all
(v
: Visitor)
990 for n
in _n_propdefs
do
995 redef meth visit_all_reverse
(v
: Visitor)
998 var i
= _n_propdefs
.length
1000 v
.visit
(_n_propdefs
[i
])
1006 redef class AMainClassdef
1008 private init empty_init
do end
1010 init init_amainclassdef
(
1011 n_propdefs
: Array[Object] # Should be Array[PPropdef]
1014 _n_propdefs
= new List[PPropdef]
1015 for n
in n_propdefs
do
1016 assert n
isa PPropdef
1022 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
1024 assert old_child
!= null
1025 for i
in [0.._n_propdefs
.length
[ do
1026 if _n_propdefs
[i
] == old_child
then
1027 if new_child
!= null then
1028 assert new_child
isa PPropdef
1029 _n_propdefs
[i
] = new_child
1030 new_child
.parent
= self
1032 _n_propdefs
.remove_at
(i
)
1039 redef meth visit_all
(v
: Visitor)
1041 for n
in _n_propdefs
do
1046 redef meth visit_all_reverse
(v
: Visitor)
1049 var i
= _n_propdefs
.length
1051 v
.visit
(_n_propdefs
[i
])
1057 redef class AConcreteClasskind
1058 redef meth n_kwclass
=(n
: TKwclass)
1066 private init empty_init
do end
1068 init init_aconcreteclasskind
(
1072 _n_kwclass
= n_kwclass
1073 if n_kwclass
!= null then
1074 n_kwclass
.parent
= self
1078 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
1080 assert old_child
!= null
1081 if _n_kwclass
== old_child
then
1082 if new_child
!= null then
1083 new_child
.parent
= self
1084 assert new_child
isa TKwclass
1085 _n_kwclass
= new_child
1093 redef meth visit_all
(v
: Visitor)
1095 if _n_kwclass
!= null then
1100 redef meth visit_all_reverse
(v
: Visitor)
1102 if _n_kwclass
!= null then
1107 redef class AAbstractClasskind
1108 redef meth n_kwabstract
=(n
: TKwabstract)
1115 redef meth n_kwclass
=(n
: TKwclass)
1123 private init empty_init
do end
1125 init init_aabstractclasskind
(
1126 n_kwabstract
: TKwabstract ,
1130 _n_kwabstract
= n_kwabstract
1131 if n_kwabstract
!= null then
1132 n_kwabstract
.parent
= self
1134 _n_kwclass
= n_kwclass
1135 if n_kwclass
!= null then
1136 n_kwclass
.parent
= self
1140 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
1142 assert old_child
!= null
1143 if _n_kwabstract
== old_child
then
1144 if new_child
!= null then
1145 new_child
.parent
= self
1146 assert new_child
isa TKwabstract
1147 _n_kwabstract
= new_child
1149 _n_kwabstract
= null
1153 if _n_kwclass
== old_child
then
1154 if new_child
!= null then
1155 new_child
.parent
= self
1156 assert new_child
isa TKwclass
1157 _n_kwclass
= new_child
1165 redef meth visit_all
(v
: Visitor)
1167 if _n_kwabstract
!= null then
1168 v
.visit
(_n_kwabstract
)
1170 if _n_kwclass
!= null then
1175 redef meth visit_all_reverse
(v
: Visitor)
1177 if _n_kwabstract
!= null then
1178 v
.visit
(_n_kwabstract
)
1180 if _n_kwclass
!= null then
1185 redef class AInterfaceClasskind
1186 redef meth n_kwinterface
=(n
: TKwinterface)
1194 private init empty_init
do end
1196 init init_ainterfaceclasskind
(
1197 n_kwinterface
: TKwinterface
1200 _n_kwinterface
= n_kwinterface
1201 if n_kwinterface
!= null then
1202 n_kwinterface
.parent
= self
1206 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
1208 assert old_child
!= null
1209 if _n_kwinterface
== old_child
then
1210 if new_child
!= null then
1211 new_child
.parent
= self
1212 assert new_child
isa TKwinterface
1213 _n_kwinterface
= new_child
1215 _n_kwinterface
= null
1221 redef meth visit_all
(v
: Visitor)
1223 if _n_kwinterface
!= null then
1224 v
.visit
(_n_kwinterface
)
1228 redef meth visit_all_reverse
(v
: Visitor)
1230 if _n_kwinterface
!= null then
1231 v
.visit
(_n_kwinterface
)
1235 redef class AUniversalClasskind
1236 redef meth n_kwuniversal
=(n
: TKwuniversal)
1244 private init empty_init
do end
1246 init init_auniversalclasskind
(
1247 n_kwuniversal
: TKwuniversal
1250 _n_kwuniversal
= n_kwuniversal
1251 if n_kwuniversal
!= null then
1252 n_kwuniversal
.parent
= self
1256 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
1258 assert old_child
!= null
1259 if _n_kwuniversal
== old_child
then
1260 if new_child
!= null then
1261 new_child
.parent
= self
1262 assert new_child
isa TKwuniversal
1263 _n_kwuniversal
= new_child
1265 _n_kwuniversal
= null
1271 redef meth visit_all
(v
: Visitor)
1273 if _n_kwuniversal
!= null then
1274 v
.visit
(_n_kwuniversal
)
1278 redef meth visit_all_reverse
(v
: Visitor)
1280 if _n_kwuniversal
!= null then
1281 v
.visit
(_n_kwuniversal
)
1285 redef class AFormaldef
1286 redef meth n_id
=(n
: TClassid)
1293 redef meth n_type
=(n
: PType)
1301 private init empty_init
do end
1303 init init_aformaldef
(
1309 if n_id
!= null then
1313 if n_type
!= null then
1314 n_type
.parent
= self
1318 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
1320 assert old_child
!= null
1321 if _n_id
== old_child
then
1322 if new_child
!= null then
1323 new_child
.parent
= self
1324 assert new_child
isa TClassid
1331 if _n_type
== old_child
then
1332 if new_child
!= null then
1333 new_child
.parent
= self
1334 assert new_child
isa PType
1343 redef meth visit_all
(v
: Visitor)
1345 if _n_id
!= null then
1348 if _n_type
!= null then
1353 redef meth visit_all_reverse
(v
: Visitor)
1355 if _n_id
!= null then
1358 if _n_type
!= null then
1363 redef class ASuperclass
1364 redef meth n_kwspecial
=(n
: TKwspecial)
1371 redef meth n_type
=(n
: PType)
1379 private init empty_init
do end
1381 init init_asuperclass
(
1382 n_kwspecial
: TKwspecial ,
1386 _n_kwspecial
= n_kwspecial
1387 if n_kwspecial
!= null then
1388 n_kwspecial
.parent
= self
1391 if n_type
!= null then
1392 n_type
.parent
= self
1396 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
1398 assert old_child
!= null
1399 if _n_kwspecial
== old_child
then
1400 if new_child
!= null then
1401 new_child
.parent
= self
1402 assert new_child
isa TKwspecial
1403 _n_kwspecial
= new_child
1409 if _n_type
== old_child
then
1410 if new_child
!= null then
1411 new_child
.parent
= self
1412 assert new_child
isa PType
1421 redef meth visit_all
(v
: Visitor)
1423 if _n_kwspecial
!= null then
1424 v
.visit
(_n_kwspecial
)
1426 if _n_type
!= null then
1431 redef meth visit_all_reverse
(v
: Visitor)
1433 if _n_kwspecial
!= null then
1434 v
.visit
(_n_kwspecial
)
1436 if _n_type
!= null then
1441 redef class AAttrPropdef
1442 redef meth n_doc
=(n
: PDoc)
1449 redef meth n_readable
=(n
: PAble)
1456 redef meth n_writable
=(n
: PAble)
1463 redef meth n_kwredef
=(n
: TKwredef)
1470 redef meth n_visibility
=(n
: PVisibility)
1477 redef meth n_kwattr
=(n
: TKwattr)
1484 redef meth n_id
=(n
: TAttrid)
1491 redef meth n_type
=(n
: PType)
1498 redef meth n_expr
=(n
: PExpr)
1506 private init empty_init
do end
1508 init init_aattrpropdef
(
1512 n_kwredef
: TKwredef ,
1513 n_visibility
: PVisibility ,
1521 if n_doc
!= null then
1524 _n_readable
= n_readable
1525 if n_readable
!= null then
1526 n_readable
.parent
= self
1528 _n_writable
= n_writable
1529 if n_writable
!= null then
1530 n_writable
.parent
= self
1532 _n_kwredef
= n_kwredef
1533 if n_kwredef
!= null then
1534 n_kwredef
.parent
= self
1536 _n_visibility
= n_visibility
1537 if n_visibility
!= null then
1538 n_visibility
.parent
= self
1540 _n_kwattr
= n_kwattr
1541 if n_kwattr
!= null then
1542 n_kwattr
.parent
= self
1545 if n_id
!= null then
1549 if n_type
!= null then
1550 n_type
.parent
= self
1553 if n_expr
!= null then
1554 n_expr
.parent
= self
1558 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
1560 assert old_child
!= null
1561 if _n_doc
== old_child
then
1562 if new_child
!= null then
1563 new_child
.parent
= self
1564 assert new_child
isa PDoc
1571 if _n_readable
== old_child
then
1572 if new_child
!= null then
1573 new_child
.parent
= self
1574 assert new_child
isa PAble
1575 _n_readable
= new_child
1581 if _n_writable
== old_child
then
1582 if new_child
!= null then
1583 new_child
.parent
= self
1584 assert new_child
isa PAble
1585 _n_writable
= new_child
1591 if _n_kwredef
== old_child
then
1592 if new_child
!= null then
1593 new_child
.parent
= self
1594 assert new_child
isa TKwredef
1595 _n_kwredef
= new_child
1601 if _n_visibility
== old_child
then
1602 if new_child
!= null then
1603 new_child
.parent
= self
1604 assert new_child
isa PVisibility
1605 _n_visibility
= new_child
1607 _n_visibility
= null
1611 if _n_kwattr
== old_child
then
1612 if new_child
!= null then
1613 new_child
.parent
= self
1614 assert new_child
isa TKwattr
1615 _n_kwattr
= new_child
1621 if _n_id
== old_child
then
1622 if new_child
!= null then
1623 new_child
.parent
= self
1624 assert new_child
isa TAttrid
1631 if _n_type
== old_child
then
1632 if new_child
!= null then
1633 new_child
.parent
= self
1634 assert new_child
isa PType
1641 if _n_expr
== old_child
then
1642 if new_child
!= null then
1643 new_child
.parent
= self
1644 assert new_child
isa PExpr
1653 redef meth visit_all
(v
: Visitor)
1655 if _n_doc
!= null then
1658 if _n_readable
!= null then
1659 v
.visit
(_n_readable
)
1661 if _n_writable
!= null then
1662 v
.visit
(_n_writable
)
1664 if _n_kwredef
!= null then
1667 if _n_visibility
!= null then
1668 v
.visit
(_n_visibility
)
1670 if _n_kwattr
!= null then
1673 if _n_id
!= null then
1676 if _n_type
!= null then
1679 if _n_expr
!= null then
1684 redef meth visit_all_reverse
(v
: Visitor)
1686 if _n_doc
!= null then
1689 if _n_readable
!= null then
1690 v
.visit
(_n_readable
)
1692 if _n_writable
!= null then
1693 v
.visit
(_n_writable
)
1695 if _n_kwredef
!= null then
1698 if _n_visibility
!= null then
1699 v
.visit
(_n_visibility
)
1701 if _n_kwattr
!= null then
1704 if _n_id
!= null then
1707 if _n_type
!= null then
1710 if _n_expr
!= null then
1715 redef class AMethPropdef
1716 redef meth n_doc
=(n
: PDoc)
1723 redef meth n_kwredef
=(n
: TKwredef)
1730 redef meth n_visibility
=(n
: PVisibility)
1737 redef meth n_methid
=(n
: PMethid)
1744 redef meth n_signature
=(n
: PSignature)
1752 private init empty_init
do end
1754 init init_amethpropdef
(
1756 n_kwredef
: TKwredef ,
1757 n_visibility
: PVisibility ,
1759 n_signature
: PSignature
1763 if n_doc
!= null then
1766 _n_kwredef
= n_kwredef
1767 if n_kwredef
!= null then
1768 n_kwredef
.parent
= self
1770 _n_visibility
= n_visibility
1771 if n_visibility
!= null then
1772 n_visibility
.parent
= self
1774 _n_methid
= n_methid
1775 if n_methid
!= null then
1776 n_methid
.parent
= self
1778 _n_signature
= n_signature
1779 if n_signature
!= null then
1780 n_signature
.parent
= self
1784 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
1786 assert old_child
!= null
1787 if _n_doc
== old_child
then
1788 if new_child
!= null then
1789 new_child
.parent
= self
1790 assert new_child
isa PDoc
1797 if _n_kwredef
== old_child
then
1798 if new_child
!= null then
1799 new_child
.parent
= self
1800 assert new_child
isa TKwredef
1801 _n_kwredef
= new_child
1807 if _n_visibility
== old_child
then
1808 if new_child
!= null then
1809 new_child
.parent
= self
1810 assert new_child
isa PVisibility
1811 _n_visibility
= new_child
1813 _n_visibility
= null
1817 if _n_methid
== old_child
then
1818 if new_child
!= null then
1819 new_child
.parent
= self
1820 assert new_child
isa PMethid
1821 _n_methid
= new_child
1827 if _n_signature
== old_child
then
1828 if new_child
!= null then
1829 new_child
.parent
= self
1830 assert new_child
isa PSignature
1831 _n_signature
= new_child
1839 redef meth visit_all
(v
: Visitor)
1841 if _n_doc
!= null then
1844 if _n_kwredef
!= null then
1847 if _n_visibility
!= null then
1848 v
.visit
(_n_visibility
)
1850 if _n_methid
!= null then
1853 if _n_signature
!= null then
1854 v
.visit
(_n_signature
)
1858 redef meth visit_all_reverse
(v
: Visitor)
1860 if _n_doc
!= null then
1863 if _n_kwredef
!= null then
1866 if _n_visibility
!= null then
1867 v
.visit
(_n_visibility
)
1869 if _n_methid
!= null then
1872 if _n_signature
!= null then
1873 v
.visit
(_n_signature
)
1877 redef class ADeferredMethPropdef
1878 redef meth n_doc
=(n
: PDoc)
1885 redef meth n_kwredef
=(n
: TKwredef)
1892 redef meth n_visibility
=(n
: PVisibility)
1899 redef meth n_kwmeth
=(n
: TKwmeth)
1906 redef meth n_methid
=(n
: PMethid)
1913 redef meth n_signature
=(n
: PSignature)
1921 private init empty_init
do end
1923 init init_adeferredmethpropdef
(
1925 n_kwredef
: TKwredef ,
1926 n_visibility
: PVisibility ,
1929 n_signature
: PSignature
1933 if n_doc
!= null then
1936 _n_kwredef
= n_kwredef
1937 if n_kwredef
!= null then
1938 n_kwredef
.parent
= self
1940 _n_visibility
= n_visibility
1941 if n_visibility
!= null then
1942 n_visibility
.parent
= self
1944 _n_kwmeth
= n_kwmeth
1945 if n_kwmeth
!= null then
1946 n_kwmeth
.parent
= self
1948 _n_methid
= n_methid
1949 if n_methid
!= null then
1950 n_methid
.parent
= self
1952 _n_signature
= n_signature
1953 if n_signature
!= null then
1954 n_signature
.parent
= self
1958 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
1960 assert old_child
!= null
1961 if _n_doc
== old_child
then
1962 if new_child
!= null then
1963 new_child
.parent
= self
1964 assert new_child
isa PDoc
1971 if _n_kwredef
== old_child
then
1972 if new_child
!= null then
1973 new_child
.parent
= self
1974 assert new_child
isa TKwredef
1975 _n_kwredef
= new_child
1981 if _n_visibility
== old_child
then
1982 if new_child
!= null then
1983 new_child
.parent
= self
1984 assert new_child
isa PVisibility
1985 _n_visibility
= new_child
1987 _n_visibility
= null
1991 if _n_kwmeth
== old_child
then
1992 if new_child
!= null then
1993 new_child
.parent
= self
1994 assert new_child
isa TKwmeth
1995 _n_kwmeth
= new_child
2001 if _n_methid
== old_child
then
2002 if new_child
!= null then
2003 new_child
.parent
= self
2004 assert new_child
isa PMethid
2005 _n_methid
= new_child
2011 if _n_signature
== old_child
then
2012 if new_child
!= null then
2013 new_child
.parent
= self
2014 assert new_child
isa PSignature
2015 _n_signature
= new_child
2023 redef meth visit_all
(v
: Visitor)
2025 if _n_doc
!= null then
2028 if _n_kwredef
!= null then
2031 if _n_visibility
!= null then
2032 v
.visit
(_n_visibility
)
2034 if _n_kwmeth
!= null then
2037 if _n_methid
!= null then
2040 if _n_signature
!= null then
2041 v
.visit
(_n_signature
)
2045 redef meth visit_all_reverse
(v
: Visitor)
2047 if _n_doc
!= null then
2050 if _n_kwredef
!= null then
2053 if _n_visibility
!= null then
2054 v
.visit
(_n_visibility
)
2056 if _n_kwmeth
!= null then
2059 if _n_methid
!= null then
2062 if _n_signature
!= null then
2063 v
.visit
(_n_signature
)
2067 redef class AInternMethPropdef
2068 redef meth n_doc
=(n
: PDoc)
2075 redef meth n_kwredef
=(n
: TKwredef)
2082 redef meth n_visibility
=(n
: PVisibility)
2089 redef meth n_kwmeth
=(n
: TKwmeth)
2096 redef meth n_methid
=(n
: PMethid)
2103 redef meth n_signature
=(n
: PSignature)
2111 private init empty_init
do end
2113 init init_ainternmethpropdef
(
2115 n_kwredef
: TKwredef ,
2116 n_visibility
: PVisibility ,
2119 n_signature
: PSignature
2123 if n_doc
!= null then
2126 _n_kwredef
= n_kwredef
2127 if n_kwredef
!= null then
2128 n_kwredef
.parent
= self
2130 _n_visibility
= n_visibility
2131 if n_visibility
!= null then
2132 n_visibility
.parent
= self
2134 _n_kwmeth
= n_kwmeth
2135 if n_kwmeth
!= null then
2136 n_kwmeth
.parent
= self
2138 _n_methid
= n_methid
2139 if n_methid
!= null then
2140 n_methid
.parent
= self
2142 _n_signature
= n_signature
2143 if n_signature
!= null then
2144 n_signature
.parent
= self
2148 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
2150 assert old_child
!= null
2151 if _n_doc
== old_child
then
2152 if new_child
!= null then
2153 new_child
.parent
= self
2154 assert new_child
isa PDoc
2161 if _n_kwredef
== old_child
then
2162 if new_child
!= null then
2163 new_child
.parent
= self
2164 assert new_child
isa TKwredef
2165 _n_kwredef
= new_child
2171 if _n_visibility
== old_child
then
2172 if new_child
!= null then
2173 new_child
.parent
= self
2174 assert new_child
isa PVisibility
2175 _n_visibility
= new_child
2177 _n_visibility
= null
2181 if _n_kwmeth
== old_child
then
2182 if new_child
!= null then
2183 new_child
.parent
= self
2184 assert new_child
isa TKwmeth
2185 _n_kwmeth
= new_child
2191 if _n_methid
== old_child
then
2192 if new_child
!= null then
2193 new_child
.parent
= self
2194 assert new_child
isa PMethid
2195 _n_methid
= new_child
2201 if _n_signature
== old_child
then
2202 if new_child
!= null then
2203 new_child
.parent
= self
2204 assert new_child
isa PSignature
2205 _n_signature
= new_child
2213 redef meth visit_all
(v
: Visitor)
2215 if _n_doc
!= null then
2218 if _n_kwredef
!= null then
2221 if _n_visibility
!= null then
2222 v
.visit
(_n_visibility
)
2224 if _n_kwmeth
!= null then
2227 if _n_methid
!= null then
2230 if _n_signature
!= null then
2231 v
.visit
(_n_signature
)
2235 redef meth visit_all_reverse
(v
: Visitor)
2237 if _n_doc
!= null then
2240 if _n_kwredef
!= null then
2243 if _n_visibility
!= null then
2244 v
.visit
(_n_visibility
)
2246 if _n_kwmeth
!= null then
2249 if _n_methid
!= null then
2252 if _n_signature
!= null then
2253 v
.visit
(_n_signature
)
2257 redef class AExternMethPropdef
2258 redef meth n_doc
=(n
: PDoc)
2265 redef meth n_kwredef
=(n
: TKwredef)
2272 redef meth n_visibility
=(n
: PVisibility)
2279 redef meth n_kwmeth
=(n
: TKwmeth)
2286 redef meth n_methid
=(n
: PMethid)
2293 redef meth n_signature
=(n
: PSignature)
2300 redef meth n_extern
=(n
: TString)
2308 private init empty_init
do end
2310 init init_aexternmethpropdef
(
2312 n_kwredef
: TKwredef ,
2313 n_visibility
: PVisibility ,
2316 n_signature
: PSignature ,
2321 if n_doc
!= null then
2324 _n_kwredef
= n_kwredef
2325 if n_kwredef
!= null then
2326 n_kwredef
.parent
= self
2328 _n_visibility
= n_visibility
2329 if n_visibility
!= null then
2330 n_visibility
.parent
= self
2332 _n_kwmeth
= n_kwmeth
2333 if n_kwmeth
!= null then
2334 n_kwmeth
.parent
= self
2336 _n_methid
= n_methid
2337 if n_methid
!= null then
2338 n_methid
.parent
= self
2340 _n_signature
= n_signature
2341 if n_signature
!= null then
2342 n_signature
.parent
= self
2344 _n_extern
= n_extern
2345 if n_extern
!= null then
2346 n_extern
.parent
= self
2350 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
2352 assert old_child
!= null
2353 if _n_doc
== old_child
then
2354 if new_child
!= null then
2355 new_child
.parent
= self
2356 assert new_child
isa PDoc
2363 if _n_kwredef
== old_child
then
2364 if new_child
!= null then
2365 new_child
.parent
= self
2366 assert new_child
isa TKwredef
2367 _n_kwredef
= new_child
2373 if _n_visibility
== old_child
then
2374 if new_child
!= null then
2375 new_child
.parent
= self
2376 assert new_child
isa PVisibility
2377 _n_visibility
= new_child
2379 _n_visibility
= null
2383 if _n_kwmeth
== old_child
then
2384 if new_child
!= null then
2385 new_child
.parent
= self
2386 assert new_child
isa TKwmeth
2387 _n_kwmeth
= new_child
2393 if _n_methid
== old_child
then
2394 if new_child
!= null then
2395 new_child
.parent
= self
2396 assert new_child
isa PMethid
2397 _n_methid
= new_child
2403 if _n_signature
== old_child
then
2404 if new_child
!= null then
2405 new_child
.parent
= self
2406 assert new_child
isa PSignature
2407 _n_signature
= new_child
2413 if _n_extern
== old_child
then
2414 if new_child
!= null then
2415 new_child
.parent
= self
2416 assert new_child
isa TString
2417 _n_extern
= new_child
2425 redef meth visit_all
(v
: Visitor)
2427 if _n_doc
!= null then
2430 if _n_kwredef
!= null then
2433 if _n_visibility
!= null then
2434 v
.visit
(_n_visibility
)
2436 if _n_kwmeth
!= null then
2439 if _n_methid
!= null then
2442 if _n_signature
!= null then
2443 v
.visit
(_n_signature
)
2445 if _n_extern
!= null then
2450 redef meth visit_all_reverse
(v
: Visitor)
2452 if _n_doc
!= null then
2455 if _n_kwredef
!= null then
2458 if _n_visibility
!= null then
2459 v
.visit
(_n_visibility
)
2461 if _n_kwmeth
!= null then
2464 if _n_methid
!= null then
2467 if _n_signature
!= null then
2468 v
.visit
(_n_signature
)
2470 if _n_extern
!= null then
2475 redef class AConcreteMethPropdef
2476 redef meth n_doc
=(n
: PDoc)
2483 redef meth n_kwredef
=(n
: TKwredef)
2490 redef meth n_visibility
=(n
: PVisibility)
2497 redef meth n_kwmeth
=(n
: TKwmeth)
2504 redef meth n_methid
=(n
: PMethid)
2511 redef meth n_signature
=(n
: PSignature)
2518 redef meth n_block
=(n
: PExpr)
2526 private init empty_init
do end
2528 init init_aconcretemethpropdef
(
2530 n_kwredef
: TKwredef ,
2531 n_visibility
: PVisibility ,
2534 n_signature
: PSignature ,
2539 if n_doc
!= null then
2542 _n_kwredef
= n_kwredef
2543 if n_kwredef
!= null then
2544 n_kwredef
.parent
= self
2546 _n_visibility
= n_visibility
2547 if n_visibility
!= null then
2548 n_visibility
.parent
= self
2550 _n_kwmeth
= n_kwmeth
2551 if n_kwmeth
!= null then
2552 n_kwmeth
.parent
= self
2554 _n_methid
= n_methid
2555 if n_methid
!= null then
2556 n_methid
.parent
= self
2558 _n_signature
= n_signature
2559 if n_signature
!= null then
2560 n_signature
.parent
= self
2563 if n_block
!= null then
2564 n_block
.parent
= self
2568 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
2570 assert old_child
!= null
2571 if _n_doc
== old_child
then
2572 if new_child
!= null then
2573 new_child
.parent
= self
2574 assert new_child
isa PDoc
2581 if _n_kwredef
== old_child
then
2582 if new_child
!= null then
2583 new_child
.parent
= self
2584 assert new_child
isa TKwredef
2585 _n_kwredef
= new_child
2591 if _n_visibility
== old_child
then
2592 if new_child
!= null then
2593 new_child
.parent
= self
2594 assert new_child
isa PVisibility
2595 _n_visibility
= new_child
2597 _n_visibility
= null
2601 if _n_kwmeth
== old_child
then
2602 if new_child
!= null then
2603 new_child
.parent
= self
2604 assert new_child
isa TKwmeth
2605 _n_kwmeth
= new_child
2611 if _n_methid
== old_child
then
2612 if new_child
!= null then
2613 new_child
.parent
= self
2614 assert new_child
isa PMethid
2615 _n_methid
= new_child
2621 if _n_signature
== old_child
then
2622 if new_child
!= null then
2623 new_child
.parent
= self
2624 assert new_child
isa PSignature
2625 _n_signature
= new_child
2631 if _n_block
== old_child
then
2632 if new_child
!= null then
2633 new_child
.parent
= self
2634 assert new_child
isa PExpr
2635 _n_block
= new_child
2643 redef meth visit_all
(v
: Visitor)
2645 if _n_doc
!= null then
2648 if _n_kwredef
!= null then
2651 if _n_visibility
!= null then
2652 v
.visit
(_n_visibility
)
2654 if _n_kwmeth
!= null then
2657 if _n_methid
!= null then
2660 if _n_signature
!= null then
2661 v
.visit
(_n_signature
)
2663 if _n_block
!= null then
2668 redef meth visit_all_reverse
(v
: Visitor)
2670 if _n_doc
!= null then
2673 if _n_kwredef
!= null then
2676 if _n_visibility
!= null then
2677 v
.visit
(_n_visibility
)
2679 if _n_kwmeth
!= null then
2682 if _n_methid
!= null then
2685 if _n_signature
!= null then
2686 v
.visit
(_n_signature
)
2688 if _n_block
!= null then
2693 redef class AConcreteInitPropdef
2694 redef meth n_doc
=(n
: PDoc)
2701 redef meth n_kwredef
=(n
: TKwredef)
2708 redef meth n_visibility
=(n
: PVisibility)
2715 redef meth n_kwinit
=(n
: TKwinit)
2722 redef meth n_methid
=(n
: PMethid)
2729 redef meth n_signature
=(n
: PSignature)
2736 redef meth n_block
=(n
: PExpr)
2744 private init empty_init
do end
2746 init init_aconcreteinitpropdef
(
2748 n_kwredef
: TKwredef ,
2749 n_visibility
: PVisibility ,
2752 n_signature
: PSignature ,
2757 if n_doc
!= null then
2760 _n_kwredef
= n_kwredef
2761 if n_kwredef
!= null then
2762 n_kwredef
.parent
= self
2764 _n_visibility
= n_visibility
2765 if n_visibility
!= null then
2766 n_visibility
.parent
= self
2768 _n_kwinit
= n_kwinit
2769 if n_kwinit
!= null then
2770 n_kwinit
.parent
= self
2772 _n_methid
= n_methid
2773 if n_methid
!= null then
2774 n_methid
.parent
= self
2776 _n_signature
= n_signature
2777 if n_signature
!= null then
2778 n_signature
.parent
= self
2781 if n_block
!= null then
2782 n_block
.parent
= self
2786 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
2788 assert old_child
!= null
2789 if _n_doc
== old_child
then
2790 if new_child
!= null then
2791 new_child
.parent
= self
2792 assert new_child
isa PDoc
2799 if _n_kwredef
== old_child
then
2800 if new_child
!= null then
2801 new_child
.parent
= self
2802 assert new_child
isa TKwredef
2803 _n_kwredef
= new_child
2809 if _n_visibility
== old_child
then
2810 if new_child
!= null then
2811 new_child
.parent
= self
2812 assert new_child
isa PVisibility
2813 _n_visibility
= new_child
2815 _n_visibility
= null
2819 if _n_kwinit
== old_child
then
2820 if new_child
!= null then
2821 new_child
.parent
= self
2822 assert new_child
isa TKwinit
2823 _n_kwinit
= new_child
2829 if _n_methid
== old_child
then
2830 if new_child
!= null then
2831 new_child
.parent
= self
2832 assert new_child
isa PMethid
2833 _n_methid
= new_child
2839 if _n_signature
== old_child
then
2840 if new_child
!= null then
2841 new_child
.parent
= self
2842 assert new_child
isa PSignature
2843 _n_signature
= new_child
2849 if _n_block
== old_child
then
2850 if new_child
!= null then
2851 new_child
.parent
= self
2852 assert new_child
isa PExpr
2853 _n_block
= new_child
2861 redef meth visit_all
(v
: Visitor)
2863 if _n_doc
!= null then
2866 if _n_kwredef
!= null then
2869 if _n_visibility
!= null then
2870 v
.visit
(_n_visibility
)
2872 if _n_kwinit
!= null then
2875 if _n_methid
!= null then
2878 if _n_signature
!= null then
2879 v
.visit
(_n_signature
)
2881 if _n_block
!= null then
2886 redef meth visit_all_reverse
(v
: Visitor)
2888 if _n_doc
!= null then
2891 if _n_kwredef
!= null then
2894 if _n_visibility
!= null then
2895 v
.visit
(_n_visibility
)
2897 if _n_kwinit
!= null then
2900 if _n_methid
!= null then
2903 if _n_signature
!= null then
2904 v
.visit
(_n_signature
)
2906 if _n_block
!= null then
2911 redef class AMainMethPropdef
2912 redef meth n_kwredef
=(n
: TKwredef)
2919 redef meth n_block
=(n
: PExpr)
2927 private init empty_init
do end
2929 init init_amainmethpropdef
(
2930 n_kwredef
: TKwredef ,
2934 _n_kwredef
= n_kwredef
2935 if n_kwredef
!= null then
2936 n_kwredef
.parent
= self
2939 if n_block
!= null then
2940 n_block
.parent
= self
2944 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
2946 assert old_child
!= null
2947 if _n_kwredef
== old_child
then
2948 if new_child
!= null then
2949 new_child
.parent
= self
2950 assert new_child
isa TKwredef
2951 _n_kwredef
= new_child
2957 if _n_block
== old_child
then
2958 if new_child
!= null then
2959 new_child
.parent
= self
2960 assert new_child
isa PExpr
2961 _n_block
= new_child
2969 redef meth visit_all
(v
: Visitor)
2971 if _n_kwredef
!= null then
2974 if _n_block
!= null then
2979 redef meth visit_all_reverse
(v
: Visitor)
2981 if _n_kwredef
!= null then
2984 if _n_block
!= null then
2989 redef class ATypePropdef
2990 redef meth n_doc
=(n
: PDoc)
2997 redef meth n_kwredef
=(n
: TKwredef)
3004 redef meth n_visibility
=(n
: PVisibility)
3011 redef meth n_kwtype
=(n
: TKwtype)
3018 redef meth n_id
=(n
: TClassid)
3025 redef meth n_type
=(n
: PType)
3033 private init empty_init
do end
3035 init init_atypepropdef
(
3037 n_kwredef
: TKwredef ,
3038 n_visibility
: PVisibility ,
3045 if n_doc
!= null then
3048 _n_kwredef
= n_kwredef
3049 if n_kwredef
!= null then
3050 n_kwredef
.parent
= self
3052 _n_visibility
= n_visibility
3053 if n_visibility
!= null then
3054 n_visibility
.parent
= self
3056 _n_kwtype
= n_kwtype
3057 if n_kwtype
!= null then
3058 n_kwtype
.parent
= self
3061 if n_id
!= null then
3065 if n_type
!= null then
3066 n_type
.parent
= self
3070 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3072 assert old_child
!= null
3073 if _n_doc
== old_child
then
3074 if new_child
!= null then
3075 new_child
.parent
= self
3076 assert new_child
isa PDoc
3083 if _n_kwredef
== old_child
then
3084 if new_child
!= null then
3085 new_child
.parent
= self
3086 assert new_child
isa TKwredef
3087 _n_kwredef
= new_child
3093 if _n_visibility
== old_child
then
3094 if new_child
!= null then
3095 new_child
.parent
= self
3096 assert new_child
isa PVisibility
3097 _n_visibility
= new_child
3099 _n_visibility
= null
3103 if _n_kwtype
== old_child
then
3104 if new_child
!= null then
3105 new_child
.parent
= self
3106 assert new_child
isa TKwtype
3107 _n_kwtype
= new_child
3113 if _n_id
== old_child
then
3114 if new_child
!= null then
3115 new_child
.parent
= self
3116 assert new_child
isa TClassid
3123 if _n_type
== old_child
then
3124 if new_child
!= null then
3125 new_child
.parent
= self
3126 assert new_child
isa PType
3135 redef meth visit_all
(v
: Visitor)
3137 if _n_doc
!= null then
3140 if _n_kwredef
!= null then
3143 if _n_visibility
!= null then
3144 v
.visit
(_n_visibility
)
3146 if _n_kwtype
!= null then
3149 if _n_id
!= null then
3152 if _n_type
!= null then
3157 redef meth visit_all_reverse
(v
: Visitor)
3159 if _n_doc
!= null then
3162 if _n_kwredef
!= null then
3165 if _n_visibility
!= null then
3166 v
.visit
(_n_visibility
)
3168 if _n_kwtype
!= null then
3171 if _n_id
!= null then
3174 if _n_type
!= null then
3179 redef class AReadAble
3180 redef meth n_kwredef
=(n
: TKwredef)
3187 redef meth n_kwreadable
=(n
: TKwreadable)
3195 private init empty_init
do end
3197 init init_areadable
(
3198 n_kwredef
: TKwredef ,
3199 n_kwreadable
: TKwreadable
3202 _n_kwredef
= n_kwredef
3203 if n_kwredef
!= null then
3204 n_kwredef
.parent
= self
3206 _n_kwreadable
= n_kwreadable
3207 if n_kwreadable
!= null then
3208 n_kwreadable
.parent
= self
3212 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3214 assert old_child
!= null
3215 if _n_kwredef
== old_child
then
3216 if new_child
!= null then
3217 new_child
.parent
= self
3218 assert new_child
isa TKwredef
3219 _n_kwredef
= new_child
3225 if _n_kwreadable
== old_child
then
3226 if new_child
!= null then
3227 new_child
.parent
= self
3228 assert new_child
isa TKwreadable
3229 _n_kwreadable
= new_child
3231 _n_kwreadable
= null
3237 redef meth visit_all
(v
: Visitor)
3239 if _n_kwredef
!= null then
3242 if _n_kwreadable
!= null then
3243 v
.visit
(_n_kwreadable
)
3247 redef meth visit_all_reverse
(v
: Visitor)
3249 if _n_kwredef
!= null then
3252 if _n_kwreadable
!= null then
3253 v
.visit
(_n_kwreadable
)
3257 redef class AWriteAble
3258 redef meth n_kwredef
=(n
: TKwredef)
3265 redef meth n_kwwritable
=(n
: TKwwritable)
3273 private init empty_init
do end
3275 init init_awriteable
(
3276 n_kwredef
: TKwredef ,
3277 n_kwwritable
: TKwwritable
3280 _n_kwredef
= n_kwredef
3281 if n_kwredef
!= null then
3282 n_kwredef
.parent
= self
3284 _n_kwwritable
= n_kwwritable
3285 if n_kwwritable
!= null then
3286 n_kwwritable
.parent
= self
3290 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3292 assert old_child
!= null
3293 if _n_kwredef
== old_child
then
3294 if new_child
!= null then
3295 new_child
.parent
= self
3296 assert new_child
isa TKwredef
3297 _n_kwredef
= new_child
3303 if _n_kwwritable
== old_child
then
3304 if new_child
!= null then
3305 new_child
.parent
= self
3306 assert new_child
isa TKwwritable
3307 _n_kwwritable
= new_child
3309 _n_kwwritable
= null
3315 redef meth visit_all
(v
: Visitor)
3317 if _n_kwredef
!= null then
3320 if _n_kwwritable
!= null then
3321 v
.visit
(_n_kwwritable
)
3325 redef meth visit_all_reverse
(v
: Visitor)
3327 if _n_kwredef
!= null then
3330 if _n_kwwritable
!= null then
3331 v
.visit
(_n_kwwritable
)
3335 redef class AIdMethid
3336 redef meth n_id
=(n
: TId)
3344 private init empty_init
do end
3346 init init_aidmethid
(
3351 if n_id
!= null then
3356 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3358 assert old_child
!= null
3359 if _n_id
== old_child
then
3360 if new_child
!= null then
3361 new_child
.parent
= self
3362 assert new_child
isa TId
3371 redef meth visit_all
(v
: Visitor)
3373 if _n_id
!= null then
3378 redef meth visit_all_reverse
(v
: Visitor)
3380 if _n_id
!= null then
3385 redef class APlusMethid
3386 redef meth n_plus
=(n
: TPlus)
3394 private init empty_init
do end
3396 init init_aplusmethid
(
3401 if n_plus
!= null then
3402 n_plus
.parent
= self
3406 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3408 assert old_child
!= null
3409 if _n_plus
== old_child
then
3410 if new_child
!= null then
3411 new_child
.parent
= self
3412 assert new_child
isa TPlus
3421 redef meth visit_all
(v
: Visitor)
3423 if _n_plus
!= null then
3428 redef meth visit_all_reverse
(v
: Visitor)
3430 if _n_plus
!= null then
3435 redef class AMinusMethid
3436 redef meth n_minus
=(n
: TMinus)
3444 private init empty_init
do end
3446 init init_aminusmethid
(
3451 if n_minus
!= null then
3452 n_minus
.parent
= self
3456 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3458 assert old_child
!= null
3459 if _n_minus
== old_child
then
3460 if new_child
!= null then
3461 new_child
.parent
= self
3462 assert new_child
isa TMinus
3463 _n_minus
= new_child
3471 redef meth visit_all
(v
: Visitor)
3473 if _n_minus
!= null then
3478 redef meth visit_all_reverse
(v
: Visitor)
3480 if _n_minus
!= null then
3485 redef class AStarMethid
3486 redef meth n_star
=(n
: TStar)
3494 private init empty_init
do end
3496 init init_astarmethid
(
3501 if n_star
!= null then
3502 n_star
.parent
= self
3506 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3508 assert old_child
!= null
3509 if _n_star
== old_child
then
3510 if new_child
!= null then
3511 new_child
.parent
= self
3512 assert new_child
isa TStar
3521 redef meth visit_all
(v
: Visitor)
3523 if _n_star
!= null then
3528 redef meth visit_all_reverse
(v
: Visitor)
3530 if _n_star
!= null then
3535 redef class ASlashMethid
3536 redef meth n_slash
=(n
: TSlash)
3544 private init empty_init
do end
3546 init init_aslashmethid
(
3551 if n_slash
!= null then
3552 n_slash
.parent
= self
3556 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3558 assert old_child
!= null
3559 if _n_slash
== old_child
then
3560 if new_child
!= null then
3561 new_child
.parent
= self
3562 assert new_child
isa TSlash
3563 _n_slash
= new_child
3571 redef meth visit_all
(v
: Visitor)
3573 if _n_slash
!= null then
3578 redef meth visit_all_reverse
(v
: Visitor)
3580 if _n_slash
!= null then
3585 redef class APercentMethid
3586 redef meth n_percent
=(n
: TPercent)
3594 private init empty_init
do end
3596 init init_apercentmethid
(
3600 _n_percent
= n_percent
3601 if n_percent
!= null then
3602 n_percent
.parent
= self
3606 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3608 assert old_child
!= null
3609 if _n_percent
== old_child
then
3610 if new_child
!= null then
3611 new_child
.parent
= self
3612 assert new_child
isa TPercent
3613 _n_percent
= new_child
3621 redef meth visit_all
(v
: Visitor)
3623 if _n_percent
!= null then
3628 redef meth visit_all_reverse
(v
: Visitor)
3630 if _n_percent
!= null then
3635 redef class AEqMethid
3636 redef meth n_eq
=(n
: TEq)
3644 private init empty_init
do end
3646 init init_aeqmethid
(
3651 if n_eq
!= null then
3656 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3658 assert old_child
!= null
3659 if _n_eq
== old_child
then
3660 if new_child
!= null then
3661 new_child
.parent
= self
3662 assert new_child
isa TEq
3671 redef meth visit_all
(v
: Visitor)
3673 if _n_eq
!= null then
3678 redef meth visit_all_reverse
(v
: Visitor)
3680 if _n_eq
!= null then
3685 redef class ANeMethid
3686 redef meth n_ne
=(n
: TNe)
3694 private init empty_init
do end
3696 init init_anemethid
(
3701 if n_ne
!= null then
3706 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3708 assert old_child
!= null
3709 if _n_ne
== old_child
then
3710 if new_child
!= null then
3711 new_child
.parent
= self
3712 assert new_child
isa TNe
3721 redef meth visit_all
(v
: Visitor)
3723 if _n_ne
!= null then
3728 redef meth visit_all_reverse
(v
: Visitor)
3730 if _n_ne
!= null then
3735 redef class ALeMethid
3736 redef meth n_le
=(n
: TLe)
3744 private init empty_init
do end
3746 init init_alemethid
(
3751 if n_le
!= null then
3756 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3758 assert old_child
!= null
3759 if _n_le
== old_child
then
3760 if new_child
!= null then
3761 new_child
.parent
= self
3762 assert new_child
isa TLe
3771 redef meth visit_all
(v
: Visitor)
3773 if _n_le
!= null then
3778 redef meth visit_all_reverse
(v
: Visitor)
3780 if _n_le
!= null then
3785 redef class AGeMethid
3786 redef meth n_ge
=(n
: TGe)
3794 private init empty_init
do end
3796 init init_agemethid
(
3801 if n_ge
!= null then
3806 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3808 assert old_child
!= null
3809 if _n_ge
== old_child
then
3810 if new_child
!= null then
3811 new_child
.parent
= self
3812 assert new_child
isa TGe
3821 redef meth visit_all
(v
: Visitor)
3823 if _n_ge
!= null then
3828 redef meth visit_all_reverse
(v
: Visitor)
3830 if _n_ge
!= null then
3835 redef class ALtMethid
3836 redef meth n_lt
=(n
: TLt)
3844 private init empty_init
do end
3846 init init_altmethid
(
3851 if n_lt
!= null then
3856 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3858 assert old_child
!= null
3859 if _n_lt
== old_child
then
3860 if new_child
!= null then
3861 new_child
.parent
= self
3862 assert new_child
isa TLt
3871 redef meth visit_all
(v
: Visitor)
3873 if _n_lt
!= null then
3878 redef meth visit_all_reverse
(v
: Visitor)
3880 if _n_lt
!= null then
3885 redef class AGtMethid
3886 redef meth n_gt
=(n
: TGt)
3894 private init empty_init
do end
3896 init init_agtmethid
(
3901 if n_gt
!= null then
3906 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3908 assert old_child
!= null
3909 if _n_gt
== old_child
then
3910 if new_child
!= null then
3911 new_child
.parent
= self
3912 assert new_child
isa TGt
3921 redef meth visit_all
(v
: Visitor)
3923 if _n_gt
!= null then
3928 redef meth visit_all_reverse
(v
: Visitor)
3930 if _n_gt
!= null then
3935 redef class ABraMethid
3936 redef meth n_obra
=(n
: TObra)
3943 redef meth n_cbra
=(n
: TCbra)
3951 private init empty_init
do end
3953 init init_abramethid
(
3959 if n_obra
!= null then
3960 n_obra
.parent
= self
3963 if n_cbra
!= null then
3964 n_cbra
.parent
= self
3968 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3970 assert old_child
!= null
3971 if _n_obra
== old_child
then
3972 if new_child
!= null then
3973 new_child
.parent
= self
3974 assert new_child
isa TObra
3981 if _n_cbra
== old_child
then
3982 if new_child
!= null then
3983 new_child
.parent
= self
3984 assert new_child
isa TCbra
3993 redef meth visit_all
(v
: Visitor)
3995 if _n_obra
!= null then
3998 if _n_cbra
!= null then
4003 redef meth visit_all_reverse
(v
: Visitor)
4005 if _n_obra
!= null then
4008 if _n_cbra
!= null then
4013 redef class AStarshipMethid
4014 redef meth n_starship
=(n
: TStarship)
4022 private init empty_init
do end
4024 init init_astarshipmethid
(
4025 n_starship
: TStarship
4028 _n_starship
= n_starship
4029 if n_starship
!= null then
4030 n_starship
.parent
= self
4034 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
4036 assert old_child
!= null
4037 if _n_starship
== old_child
then
4038 if new_child
!= null then
4039 new_child
.parent
= self
4040 assert new_child
isa TStarship
4041 _n_starship
= new_child
4049 redef meth visit_all
(v
: Visitor)
4051 if _n_starship
!= null then
4052 v
.visit
(_n_starship
)
4056 redef meth visit_all_reverse
(v
: Visitor)
4058 if _n_starship
!= null then
4059 v
.visit
(_n_starship
)
4063 redef class AAssignMethid
4064 redef meth n_id
=(n
: TId)
4071 redef meth n_assign
=(n
: TAssign)
4079 private init empty_init
do end
4081 init init_aassignmethid
(
4087 if n_id
!= null then
4090 _n_assign
= n_assign
4091 if n_assign
!= null then
4092 n_assign
.parent
= self
4096 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
4098 assert old_child
!= null
4099 if _n_id
== old_child
then
4100 if new_child
!= null then
4101 new_child
.parent
= self
4102 assert new_child
isa TId
4109 if _n_assign
== old_child
then
4110 if new_child
!= null then
4111 new_child
.parent
= self
4112 assert new_child
isa TAssign
4113 _n_assign
= new_child
4121 redef meth visit_all
(v
: Visitor)
4123 if _n_id
!= null then
4126 if _n_assign
!= null then
4131 redef meth visit_all_reverse
(v
: Visitor)
4133 if _n_id
!= null then
4136 if _n_assign
!= null then
4141 redef class ABraassignMethid
4142 redef meth n_obra
=(n
: TObra)
4149 redef meth n_cbra
=(n
: TCbra)
4156 redef meth n_assign
=(n
: TAssign)
4164 private init empty_init
do end
4166 init init_abraassignmethid
(
4173 if n_obra
!= null then
4174 n_obra
.parent
= self
4177 if n_cbra
!= null then
4178 n_cbra
.parent
= self
4180 _n_assign
= n_assign
4181 if n_assign
!= null then
4182 n_assign
.parent
= self
4186 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
4188 assert old_child
!= null
4189 if _n_obra
== old_child
then
4190 if new_child
!= null then
4191 new_child
.parent
= self
4192 assert new_child
isa TObra
4199 if _n_cbra
== old_child
then
4200 if new_child
!= null then
4201 new_child
.parent
= self
4202 assert new_child
isa TCbra
4209 if _n_assign
== old_child
then
4210 if new_child
!= null then
4211 new_child
.parent
= self
4212 assert new_child
isa TAssign
4213 _n_assign
= new_child
4221 redef meth visit_all
(v
: Visitor)
4223 if _n_obra
!= null then
4226 if _n_cbra
!= null then
4229 if _n_assign
!= null then
4234 redef meth visit_all_reverse
(v
: Visitor)
4236 if _n_obra
!= null then
4239 if _n_cbra
!= null then
4242 if _n_assign
!= null then
4247 redef class ASignature
4248 redef meth n_type
=(n
: PType)
4256 private init empty_init
do end
4258 init init_asignature
(
4259 n_params
: Array[Object] , # Should be Array[PParam]
4263 _n_params
= new List[PParam]
4264 for n
in n_params
do
4270 if n_type
!= null then
4271 n_type
.parent
= self
4275 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
4277 assert old_child
!= null
4278 for i
in [0.._n_params
.length
[ do
4279 if _n_params
[i
] == old_child
then
4280 if new_child
!= null then
4281 assert new_child
isa PParam
4282 _n_params
[i
] = new_child
4283 new_child
.parent
= self
4285 _n_params
.remove_at
(i
)
4290 if _n_type
== old_child
then
4291 if new_child
!= null then
4292 new_child
.parent
= self
4293 assert new_child
isa PType
4302 redef meth visit_all
(v
: Visitor)
4304 for n
in _n_params
do
4307 if _n_type
!= null then
4312 redef meth visit_all_reverse
(v
: Visitor)
4315 var i
= _n_params
.length
4317 v
.visit
(_n_params
[i
])
4321 if _n_type
!= null then
4327 redef meth n_id
=(n
: TId)
4334 redef meth n_type
=(n
: PType)
4341 redef meth n_dotdotdot
=(n
: TDotdotdot)
4349 private init empty_init
do end
4354 n_dotdotdot
: TDotdotdot
4358 if n_id
!= null then
4362 if n_type
!= null then
4363 n_type
.parent
= self
4365 _n_dotdotdot
= n_dotdotdot
4366 if n_dotdotdot
!= null then
4367 n_dotdotdot
.parent
= self
4371 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
4373 assert old_child
!= null
4374 if _n_id
== old_child
then
4375 if new_child
!= null then
4376 new_child
.parent
= self
4377 assert new_child
isa TId
4384 if _n_type
== old_child
then
4385 if new_child
!= null then
4386 new_child
.parent
= self
4387 assert new_child
isa PType
4394 if _n_dotdotdot
== old_child
then
4395 if new_child
!= null then
4396 new_child
.parent
= self
4397 assert new_child
isa TDotdotdot
4398 _n_dotdotdot
= new_child
4406 redef meth visit_all
(v
: Visitor)
4408 if _n_id
!= null then
4411 if _n_type
!= null then
4414 if _n_dotdotdot
!= null then
4415 v
.visit
(_n_dotdotdot
)
4419 redef meth visit_all_reverse
(v
: Visitor)
4421 if _n_id
!= null then
4424 if _n_type
!= null then
4427 if _n_dotdotdot
!= null then
4428 v
.visit
(_n_dotdotdot
)
4433 redef meth n_id
=(n
: TClassid)
4441 private init empty_init
do end
4445 n_types
: Array[Object] # Should be Array[PType]
4449 if n_id
!= null then
4452 _n_types
= new List[PType]
4460 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
4462 assert old_child
!= null
4463 if _n_id
== old_child
then
4464 if new_child
!= null then
4465 new_child
.parent
= self
4466 assert new_child
isa TClassid
4473 for i
in [0.._n_types
.length
[ do
4474 if _n_types
[i
] == old_child
then
4475 if new_child
!= null then
4476 assert new_child
isa PType
4477 _n_types
[i
] = new_child
4478 new_child
.parent
= self
4480 _n_types
.remove_at
(i
)
4487 redef meth visit_all
(v
: Visitor)
4489 if _n_id
!= null then
4492 for n
in _n_types
do
4497 redef meth visit_all_reverse
(v
: Visitor)
4499 if _n_id
!= null then
4503 var i
= _n_types
.length
4505 v
.visit
(_n_types
[i
])
4511 redef class ABlockExpr
4513 private init empty_init
do end
4515 init init_ablockexpr
(
4516 n_expr
: Array[Object] # Should be Array[PExpr]
4519 _n_expr
= new List[PExpr]
4527 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
4529 assert old_child
!= null
4530 for i
in [0.._n_expr
.length
[ do
4531 if _n_expr
[i
] == old_child
then
4532 if new_child
!= null then
4533 assert new_child
isa PExpr
4534 _n_expr
[i
] = new_child
4535 new_child
.parent
= self
4537 _n_expr
.remove_at
(i
)
4544 redef meth visit_all
(v
: Visitor)
4551 redef meth visit_all_reverse
(v
: Visitor)
4554 var i
= _n_expr
.length
4562 redef class AVardeclExpr
4563 redef meth n_kwvar
=(n
: TKwvar)
4570 redef meth n_id
=(n
: TId)
4577 redef meth n_type
=(n
: PType)
4584 redef meth n_assign
=(n
: TAssign)
4591 redef meth n_expr
=(n
: PExpr)
4599 private init empty_init
do end
4601 init init_avardeclexpr
(
4610 if n_kwvar
!= null then
4611 n_kwvar
.parent
= self
4614 if n_id
!= null then
4618 if n_type
!= null then
4619 n_type
.parent
= self
4621 _n_assign
= n_assign
4622 if n_assign
!= null then
4623 n_assign
.parent
= self
4626 if n_expr
!= null then
4627 n_expr
.parent
= self
4631 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
4633 assert old_child
!= null
4634 if _n_kwvar
== old_child
then
4635 if new_child
!= null then
4636 new_child
.parent
= self
4637 assert new_child
isa TKwvar
4638 _n_kwvar
= new_child
4644 if _n_id
== old_child
then
4645 if new_child
!= null then
4646 new_child
.parent
= self
4647 assert new_child
isa TId
4654 if _n_type
== old_child
then
4655 if new_child
!= null then
4656 new_child
.parent
= self
4657 assert new_child
isa PType
4664 if _n_assign
== old_child
then
4665 if new_child
!= null then
4666 new_child
.parent
= self
4667 assert new_child
isa TAssign
4668 _n_assign
= new_child
4674 if _n_expr
== old_child
then
4675 if new_child
!= null then
4676 new_child
.parent
= self
4677 assert new_child
isa PExpr
4686 redef meth visit_all
(v
: Visitor)
4688 if _n_kwvar
!= null then
4691 if _n_id
!= null then
4694 if _n_type
!= null then
4697 if _n_assign
!= null then
4700 if _n_expr
!= null then
4705 redef meth visit_all_reverse
(v
: Visitor)
4707 if _n_kwvar
!= null then
4710 if _n_id
!= null then
4713 if _n_type
!= null then
4716 if _n_assign
!= null then
4719 if _n_expr
!= null then
4724 redef class AReturnExpr
4725 redef meth n_kwreturn
=(n
: TKwreturn)
4732 redef meth n_expr
=(n
: PExpr)
4740 private init empty_init
do end
4742 init init_areturnexpr
(
4743 n_kwreturn
: TKwreturn ,
4747 _n_kwreturn
= n_kwreturn
4748 if n_kwreturn
!= null then
4749 n_kwreturn
.parent
= self
4752 if n_expr
!= null then
4753 n_expr
.parent
= self
4757 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
4759 assert old_child
!= null
4760 if _n_kwreturn
== old_child
then
4761 if new_child
!= null then
4762 new_child
.parent
= self
4763 assert new_child
isa TKwreturn
4764 _n_kwreturn
= new_child
4770 if _n_expr
== old_child
then
4771 if new_child
!= null then
4772 new_child
.parent
= self
4773 assert new_child
isa PExpr
4782 redef meth visit_all
(v
: Visitor)
4784 if _n_kwreturn
!= null then
4785 v
.visit
(_n_kwreturn
)
4787 if _n_expr
!= null then
4792 redef meth visit_all_reverse
(v
: Visitor)
4794 if _n_kwreturn
!= null then
4795 v
.visit
(_n_kwreturn
)
4797 if _n_expr
!= null then
4802 redef class ABreakExpr
4803 redef meth n_kwbreak
=(n
: TKwbreak)
4811 private init empty_init
do end
4813 init init_abreakexpr
(
4817 _n_kwbreak
= n_kwbreak
4818 if n_kwbreak
!= null then
4819 n_kwbreak
.parent
= self
4823 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
4825 assert old_child
!= null
4826 if _n_kwbreak
== old_child
then
4827 if new_child
!= null then
4828 new_child
.parent
= self
4829 assert new_child
isa TKwbreak
4830 _n_kwbreak
= new_child
4838 redef meth visit_all
(v
: Visitor)
4840 if _n_kwbreak
!= null then
4845 redef meth visit_all_reverse
(v
: Visitor)
4847 if _n_kwbreak
!= null then
4852 redef class AAbortExpr
4853 redef meth n_kwabort
=(n
: TKwabort)
4861 private init empty_init
do end
4863 init init_aabortexpr
(
4867 _n_kwabort
= n_kwabort
4868 if n_kwabort
!= null then
4869 n_kwabort
.parent
= self
4873 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
4875 assert old_child
!= null
4876 if _n_kwabort
== old_child
then
4877 if new_child
!= null then
4878 new_child
.parent
= self
4879 assert new_child
isa TKwabort
4880 _n_kwabort
= new_child
4888 redef meth visit_all
(v
: Visitor)
4890 if _n_kwabort
!= null then
4895 redef meth visit_all_reverse
(v
: Visitor)
4897 if _n_kwabort
!= null then
4902 redef class AContinueExpr
4903 redef meth n_kwcontinue
=(n
: TKwcontinue)
4911 private init empty_init
do end
4913 init init_acontinueexpr
(
4914 n_kwcontinue
: TKwcontinue
4917 _n_kwcontinue
= n_kwcontinue
4918 if n_kwcontinue
!= null then
4919 n_kwcontinue
.parent
= self
4923 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
4925 assert old_child
!= null
4926 if _n_kwcontinue
== old_child
then
4927 if new_child
!= null then
4928 new_child
.parent
= self
4929 assert new_child
isa TKwcontinue
4930 _n_kwcontinue
= new_child
4932 _n_kwcontinue
= null
4938 redef meth visit_all
(v
: Visitor)
4940 if _n_kwcontinue
!= null then
4941 v
.visit
(_n_kwcontinue
)
4945 redef meth visit_all_reverse
(v
: Visitor)
4947 if _n_kwcontinue
!= null then
4948 v
.visit
(_n_kwcontinue
)
4953 redef meth n_kwdo
=(n
: TKwdo)
4960 redef meth n_block
=(n
: PExpr)
4968 private init empty_init
do end
4976 if n_kwdo
!= null then
4977 n_kwdo
.parent
= self
4980 if n_block
!= null then
4981 n_block
.parent
= self
4985 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
4987 assert old_child
!= null
4988 if _n_kwdo
== old_child
then
4989 if new_child
!= null then
4990 new_child
.parent
= self
4991 assert new_child
isa TKwdo
4998 if _n_block
== old_child
then
4999 if new_child
!= null then
5000 new_child
.parent
= self
5001 assert new_child
isa PExpr
5002 _n_block
= new_child
5010 redef meth visit_all
(v
: Visitor)
5012 if _n_kwdo
!= null then
5015 if _n_block
!= null then
5020 redef meth visit_all_reverse
(v
: Visitor)
5022 if _n_kwdo
!= null then
5025 if _n_block
!= null then
5031 redef meth n_kwif
=(n
: TKwif)
5038 redef meth n_expr
=(n
: PExpr)
5045 redef meth n_then
=(n
: PExpr)
5052 redef meth n_else
=(n
: PExpr)
5060 private init empty_init
do end
5070 if n_kwif
!= null then
5071 n_kwif
.parent
= self
5074 if n_expr
!= null then
5075 n_expr
.parent
= self
5078 if n_then
!= null then
5079 n_then
.parent
= self
5082 if n_else
!= null then
5083 n_else
.parent
= self
5087 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
5089 assert old_child
!= null
5090 if _n_kwif
== old_child
then
5091 if new_child
!= null then
5092 new_child
.parent
= self
5093 assert new_child
isa TKwif
5100 if _n_expr
== old_child
then
5101 if new_child
!= null then
5102 new_child
.parent
= self
5103 assert new_child
isa PExpr
5110 if _n_then
== old_child
then
5111 if new_child
!= null then
5112 new_child
.parent
= self
5113 assert new_child
isa PExpr
5120 if _n_else
== old_child
then
5121 if new_child
!= null then
5122 new_child
.parent
= self
5123 assert new_child
isa PExpr
5132 redef meth visit_all
(v
: Visitor)
5134 if _n_kwif
!= null then
5137 if _n_expr
!= null then
5140 if _n_then
!= null then
5143 if _n_else
!= null then
5148 redef meth visit_all_reverse
(v
: Visitor)
5150 if _n_kwif
!= null then
5153 if _n_expr
!= null then
5156 if _n_then
!= null then
5159 if _n_else
!= null then
5164 redef class AIfexprExpr
5165 redef meth n_kwif
=(n
: TKwif)
5172 redef meth n_expr
=(n
: PExpr)
5179 redef meth n_kwthen
=(n
: TKwthen)
5186 redef meth n_then
=(n
: PExpr)
5193 redef meth n_kwelse
=(n
: TKwelse)
5200 redef meth n_else
=(n
: PExpr)
5208 private init empty_init
do end
5210 init init_aifexprexpr
(
5220 if n_kwif
!= null then
5221 n_kwif
.parent
= self
5224 if n_expr
!= null then
5225 n_expr
.parent
= self
5227 _n_kwthen
= n_kwthen
5228 if n_kwthen
!= null then
5229 n_kwthen
.parent
= self
5232 if n_then
!= null then
5233 n_then
.parent
= self
5235 _n_kwelse
= n_kwelse
5236 if n_kwelse
!= null then
5237 n_kwelse
.parent
= self
5240 if n_else
!= null then
5241 n_else
.parent
= self
5245 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
5247 assert old_child
!= null
5248 if _n_kwif
== old_child
then
5249 if new_child
!= null then
5250 new_child
.parent
= self
5251 assert new_child
isa TKwif
5258 if _n_expr
== old_child
then
5259 if new_child
!= null then
5260 new_child
.parent
= self
5261 assert new_child
isa PExpr
5268 if _n_kwthen
== old_child
then
5269 if new_child
!= null then
5270 new_child
.parent
= self
5271 assert new_child
isa TKwthen
5272 _n_kwthen
= new_child
5278 if _n_then
== old_child
then
5279 if new_child
!= null then
5280 new_child
.parent
= self
5281 assert new_child
isa PExpr
5288 if _n_kwelse
== old_child
then
5289 if new_child
!= null then
5290 new_child
.parent
= self
5291 assert new_child
isa TKwelse
5292 _n_kwelse
= new_child
5298 if _n_else
== old_child
then
5299 if new_child
!= null then
5300 new_child
.parent
= self
5301 assert new_child
isa PExpr
5310 redef meth visit_all
(v
: Visitor)
5312 if _n_kwif
!= null then
5315 if _n_expr
!= null then
5318 if _n_kwthen
!= null then
5321 if _n_then
!= null then
5324 if _n_kwelse
!= null then
5327 if _n_else
!= null then
5332 redef meth visit_all_reverse
(v
: Visitor)
5334 if _n_kwif
!= null then
5337 if _n_expr
!= null then
5340 if _n_kwthen
!= null then
5343 if _n_then
!= null then
5346 if _n_kwelse
!= null then
5349 if _n_else
!= null then
5354 redef class AWhileExpr
5355 redef meth n_kwwhile
=(n
: TKwwhile)
5362 redef meth n_expr
=(n
: PExpr)
5369 redef meth n_kwdo
=(n
: TKwdo)
5376 redef meth n_block
=(n
: PExpr)
5384 private init empty_init
do end
5386 init init_awhileexpr
(
5387 n_kwwhile
: TKwwhile ,
5393 _n_kwwhile
= n_kwwhile
5394 if n_kwwhile
!= null then
5395 n_kwwhile
.parent
= self
5398 if n_expr
!= null then
5399 n_expr
.parent
= self
5402 if n_kwdo
!= null then
5403 n_kwdo
.parent
= self
5406 if n_block
!= null then
5407 n_block
.parent
= self
5411 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
5413 assert old_child
!= null
5414 if _n_kwwhile
== old_child
then
5415 if new_child
!= null then
5416 new_child
.parent
= self
5417 assert new_child
isa TKwwhile
5418 _n_kwwhile
= new_child
5424 if _n_expr
== old_child
then
5425 if new_child
!= null then
5426 new_child
.parent
= self
5427 assert new_child
isa PExpr
5434 if _n_kwdo
== old_child
then
5435 if new_child
!= null then
5436 new_child
.parent
= self
5437 assert new_child
isa TKwdo
5444 if _n_block
== old_child
then
5445 if new_child
!= null then
5446 new_child
.parent
= self
5447 assert new_child
isa PExpr
5448 _n_block
= new_child
5456 redef meth visit_all
(v
: Visitor)
5458 if _n_kwwhile
!= null then
5461 if _n_expr
!= null then
5464 if _n_kwdo
!= null then
5467 if _n_block
!= null then
5472 redef meth visit_all_reverse
(v
: Visitor)
5474 if _n_kwwhile
!= null then
5477 if _n_expr
!= null then
5480 if _n_kwdo
!= null then
5483 if _n_block
!= null then
5488 redef class AForExpr
5489 redef meth n_vardecl
=(n
: PExpr)
5496 redef meth n_kwdo
=(n
: TKwdo)
5503 redef meth n_block
=(n
: PExpr)
5511 private init empty_init
do end
5513 init init_aforexpr
(
5519 _n_vardecl
= n_vardecl
5520 if n_vardecl
!= null then
5521 n_vardecl
.parent
= self
5524 if n_kwdo
!= null then
5525 n_kwdo
.parent
= self
5528 if n_block
!= null then
5529 n_block
.parent
= self
5533 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
5535 assert old_child
!= null
5536 if _n_vardecl
== old_child
then
5537 if new_child
!= null then
5538 new_child
.parent
= self
5539 assert new_child
isa PExpr
5540 _n_vardecl
= new_child
5546 if _n_kwdo
== old_child
then
5547 if new_child
!= null then
5548 new_child
.parent
= self
5549 assert new_child
isa TKwdo
5556 if _n_block
== old_child
then
5557 if new_child
!= null then
5558 new_child
.parent
= self
5559 assert new_child
isa PExpr
5560 _n_block
= new_child
5568 redef meth visit_all
(v
: Visitor)
5570 if _n_vardecl
!= null then
5573 if _n_kwdo
!= null then
5576 if _n_block
!= null then
5581 redef meth visit_all_reverse
(v
: Visitor)
5583 if _n_vardecl
!= null then
5586 if _n_kwdo
!= null then
5589 if _n_block
!= null then
5594 redef class AForVardeclExpr
5595 redef meth n_kwfor
=(n
: TKwfor)
5602 redef meth n_id
=(n
: TId)
5609 redef meth n_expr
=(n
: PExpr)
5617 private init empty_init
do end
5619 init init_aforvardeclexpr
(
5626 if n_kwfor
!= null then
5627 n_kwfor
.parent
= self
5630 if n_id
!= null then
5634 if n_expr
!= null then
5635 n_expr
.parent
= self
5639 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
5641 assert old_child
!= null
5642 if _n_kwfor
== old_child
then
5643 if new_child
!= null then
5644 new_child
.parent
= self
5645 assert new_child
isa TKwfor
5646 _n_kwfor
= new_child
5652 if _n_id
== old_child
then
5653 if new_child
!= null then
5654 new_child
.parent
= self
5655 assert new_child
isa TId
5662 if _n_expr
== old_child
then
5663 if new_child
!= null then
5664 new_child
.parent
= self
5665 assert new_child
isa PExpr
5674 redef meth visit_all
(v
: Visitor)
5676 if _n_kwfor
!= null then
5679 if _n_id
!= null then
5682 if _n_expr
!= null then
5687 redef meth visit_all_reverse
(v
: Visitor)
5689 if _n_kwfor
!= null then
5692 if _n_id
!= null then
5695 if _n_expr
!= null then
5700 redef class AAssertExpr
5701 redef meth n_kwassert
=(n
: TKwassert)
5708 redef meth n_id
=(n
: TId)
5715 redef meth n_expr
=(n
: PExpr)
5723 private init empty_init
do end
5725 init init_aassertexpr
(
5726 n_kwassert
: TKwassert ,
5731 _n_kwassert
= n_kwassert
5732 if n_kwassert
!= null then
5733 n_kwassert
.parent
= self
5736 if n_id
!= null then
5740 if n_expr
!= null then
5741 n_expr
.parent
= self
5745 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
5747 assert old_child
!= null
5748 if _n_kwassert
== old_child
then
5749 if new_child
!= null then
5750 new_child
.parent
= self
5751 assert new_child
isa TKwassert
5752 _n_kwassert
= new_child
5758 if _n_id
== old_child
then
5759 if new_child
!= null then
5760 new_child
.parent
= self
5761 assert new_child
isa TId
5768 if _n_expr
== old_child
then
5769 if new_child
!= null then
5770 new_child
.parent
= self
5771 assert new_child
isa PExpr
5780 redef meth visit_all
(v
: Visitor)
5782 if _n_kwassert
!= null then
5783 v
.visit
(_n_kwassert
)
5785 if _n_id
!= null then
5788 if _n_expr
!= null then
5793 redef meth visit_all_reverse
(v
: Visitor)
5795 if _n_kwassert
!= null then
5796 v
.visit
(_n_kwassert
)
5798 if _n_id
!= null then
5801 if _n_expr
!= null then
5806 redef class AOnceExpr
5807 redef meth n_kwonce
=(n
: TKwonce)
5814 redef meth n_expr
=(n
: PExpr)
5822 private init empty_init
do end
5824 init init_aonceexpr
(
5829 _n_kwonce
= n_kwonce
5830 if n_kwonce
!= null then
5831 n_kwonce
.parent
= self
5834 if n_expr
!= null then
5835 n_expr
.parent
= self
5839 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
5841 assert old_child
!= null
5842 if _n_kwonce
== old_child
then
5843 if new_child
!= null then
5844 new_child
.parent
= self
5845 assert new_child
isa TKwonce
5846 _n_kwonce
= new_child
5852 if _n_expr
== old_child
then
5853 if new_child
!= null then
5854 new_child
.parent
= self
5855 assert new_child
isa PExpr
5864 redef meth visit_all
(v
: Visitor)
5866 if _n_kwonce
!= null then
5869 if _n_expr
!= null then
5874 redef meth visit_all_reverse
(v
: Visitor)
5876 if _n_kwonce
!= null then
5879 if _n_expr
!= null then
5884 redef class ASendExpr
5885 redef meth n_expr
=(n
: PExpr)
5893 private init empty_init
do end
5895 init init_asendexpr
(
5900 if n_expr
!= null then
5901 n_expr
.parent
= self
5905 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
5907 assert old_child
!= null
5908 if _n_expr
== old_child
then
5909 if new_child
!= null then
5910 new_child
.parent
= self
5911 assert new_child
isa PExpr
5920 redef meth visit_all
(v
: Visitor)
5922 if _n_expr
!= null then
5927 redef meth visit_all_reverse
(v
: Visitor)
5929 if _n_expr
!= null then
5934 redef class ABinopExpr
5935 redef meth n_expr
=(n
: PExpr)
5942 redef meth n_expr2
=(n
: PExpr)
5950 private init empty_init
do end
5952 init init_abinopexpr
(
5958 if n_expr
!= null then
5959 n_expr
.parent
= self
5962 if n_expr2
!= null then
5963 n_expr2
.parent
= self
5967 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
5969 assert old_child
!= null
5970 if _n_expr
== old_child
then
5971 if new_child
!= null then
5972 new_child
.parent
= self
5973 assert new_child
isa PExpr
5980 if _n_expr2
== old_child
then
5981 if new_child
!= null then
5982 new_child
.parent
= self
5983 assert new_child
isa PExpr
5984 _n_expr2
= new_child
5992 redef meth visit_all
(v
: Visitor)
5994 if _n_expr
!= null then
5997 if _n_expr2
!= null then
6002 redef meth visit_all_reverse
(v
: Visitor)
6004 if _n_expr
!= null then
6007 if _n_expr2
!= null then
6013 redef meth n_expr
=(n
: PExpr)
6020 redef meth n_expr2
=(n
: PExpr)
6028 private init empty_init
do end
6036 if n_expr
!= null then
6037 n_expr
.parent
= self
6040 if n_expr2
!= null then
6041 n_expr2
.parent
= self
6045 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
6047 assert old_child
!= null
6048 if _n_expr
== old_child
then
6049 if new_child
!= null then
6050 new_child
.parent
= self
6051 assert new_child
isa PExpr
6058 if _n_expr2
== old_child
then
6059 if new_child
!= null then
6060 new_child
.parent
= self
6061 assert new_child
isa PExpr
6062 _n_expr2
= new_child
6070 redef meth visit_all
(v
: Visitor)
6072 if _n_expr
!= null then
6075 if _n_expr2
!= null then
6080 redef meth visit_all_reverse
(v
: Visitor)
6082 if _n_expr
!= null then
6085 if _n_expr2
!= null then
6090 redef class AAndExpr
6091 redef meth n_expr
=(n
: PExpr)
6098 redef meth n_expr2
=(n
: PExpr)
6106 private init empty_init
do end
6108 init init_aandexpr
(
6114 if n_expr
!= null then
6115 n_expr
.parent
= self
6118 if n_expr2
!= null then
6119 n_expr2
.parent
= self
6123 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
6125 assert old_child
!= null
6126 if _n_expr
== old_child
then
6127 if new_child
!= null then
6128 new_child
.parent
= self
6129 assert new_child
isa PExpr
6136 if _n_expr2
== old_child
then
6137 if new_child
!= null then
6138 new_child
.parent
= self
6139 assert new_child
isa PExpr
6140 _n_expr2
= new_child
6148 redef meth visit_all
(v
: Visitor)
6150 if _n_expr
!= null then
6153 if _n_expr2
!= null then
6158 redef meth visit_all_reverse
(v
: Visitor)
6160 if _n_expr
!= null then
6163 if _n_expr2
!= null then
6168 redef class ANotExpr
6169 redef meth n_kwnot
=(n
: TKwnot)
6176 redef meth n_expr
=(n
: PExpr)
6184 private init empty_init
do end
6186 init init_anotexpr
(
6192 if n_kwnot
!= null then
6193 n_kwnot
.parent
= self
6196 if n_expr
!= null then
6197 n_expr
.parent
= self
6201 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
6203 assert old_child
!= null
6204 if _n_kwnot
== old_child
then
6205 if new_child
!= null then
6206 new_child
.parent
= self
6207 assert new_child
isa TKwnot
6208 _n_kwnot
= new_child
6214 if _n_expr
== old_child
then
6215 if new_child
!= null then
6216 new_child
.parent
= self
6217 assert new_child
isa PExpr
6226 redef meth visit_all
(v
: Visitor)
6228 if _n_kwnot
!= null then
6231 if _n_expr
!= null then
6236 redef meth visit_all_reverse
(v
: Visitor)
6238 if _n_kwnot
!= null then
6241 if _n_expr
!= null then
6247 redef meth n_expr
=(n
: PExpr)
6254 redef meth n_expr2
=(n
: PExpr)
6262 private init empty_init
do end
6270 if n_expr
!= null then
6271 n_expr
.parent
= self
6274 if n_expr2
!= null then
6275 n_expr2
.parent
= self
6279 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
6281 assert old_child
!= null
6282 if _n_expr
== old_child
then
6283 if new_child
!= null then
6284 new_child
.parent
= self
6285 assert new_child
isa PExpr
6292 if _n_expr2
== old_child
then
6293 if new_child
!= null then
6294 new_child
.parent
= self
6295 assert new_child
isa PExpr
6296 _n_expr2
= new_child
6304 redef meth visit_all
(v
: Visitor)
6306 if _n_expr
!= null then
6309 if _n_expr2
!= null then
6314 redef meth visit_all_reverse
(v
: Visitor)
6316 if _n_expr
!= null then
6319 if _n_expr2
!= null then
6325 redef meth n_expr
=(n
: PExpr)
6332 redef meth n_expr2
=(n
: PExpr)
6340 private init empty_init
do end
6348 if n_expr
!= null then
6349 n_expr
.parent
= self
6352 if n_expr2
!= null then
6353 n_expr2
.parent
= self
6357 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
6359 assert old_child
!= null
6360 if _n_expr
== old_child
then
6361 if new_child
!= null then
6362 new_child
.parent
= self
6363 assert new_child
isa PExpr
6370 if _n_expr2
== old_child
then
6371 if new_child
!= null then
6372 new_child
.parent
= self
6373 assert new_child
isa PExpr
6374 _n_expr2
= new_child
6382 redef meth visit_all
(v
: Visitor)
6384 if _n_expr
!= null then
6387 if _n_expr2
!= null then
6392 redef meth visit_all_reverse
(v
: Visitor)
6394 if _n_expr
!= null then
6397 if _n_expr2
!= null then
6403 redef meth n_expr
=(n
: PExpr)
6410 redef meth n_expr2
=(n
: PExpr)
6418 private init empty_init
do end
6426 if n_expr
!= null then
6427 n_expr
.parent
= self
6430 if n_expr2
!= null then
6431 n_expr2
.parent
= self
6435 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
6437 assert old_child
!= null
6438 if _n_expr
== old_child
then
6439 if new_child
!= null then
6440 new_child
.parent
= self
6441 assert new_child
isa PExpr
6448 if _n_expr2
== old_child
then
6449 if new_child
!= null then
6450 new_child
.parent
= self
6451 assert new_child
isa PExpr
6452 _n_expr2
= new_child
6460 redef meth visit_all
(v
: Visitor)
6462 if _n_expr
!= null then
6465 if _n_expr2
!= null then
6470 redef meth visit_all_reverse
(v
: Visitor)
6472 if _n_expr
!= null then
6475 if _n_expr2
!= null then
6481 redef meth n_expr
=(n
: PExpr)
6488 redef meth n_expr2
=(n
: PExpr)
6496 private init empty_init
do end
6504 if n_expr
!= null then
6505 n_expr
.parent
= self
6508 if n_expr2
!= null then
6509 n_expr2
.parent
= self
6513 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
6515 assert old_child
!= null
6516 if _n_expr
== old_child
then
6517 if new_child
!= null then
6518 new_child
.parent
= self
6519 assert new_child
isa PExpr
6526 if _n_expr2
== old_child
then
6527 if new_child
!= null then
6528 new_child
.parent
= self
6529 assert new_child
isa PExpr
6530 _n_expr2
= new_child
6538 redef meth visit_all
(v
: Visitor)
6540 if _n_expr
!= null then
6543 if _n_expr2
!= null then
6548 redef meth visit_all_reverse
(v
: Visitor)
6550 if _n_expr
!= null then
6553 if _n_expr2
!= null then
6559 redef meth n_expr
=(n
: PExpr)
6566 redef meth n_expr2
=(n
: PExpr)
6574 private init empty_init
do end
6582 if n_expr
!= null then
6583 n_expr
.parent
= self
6586 if n_expr2
!= null then
6587 n_expr2
.parent
= self
6591 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
6593 assert old_child
!= null
6594 if _n_expr
== old_child
then
6595 if new_child
!= null then
6596 new_child
.parent
= self
6597 assert new_child
isa PExpr
6604 if _n_expr2
== old_child
then
6605 if new_child
!= null then
6606 new_child
.parent
= self
6607 assert new_child
isa PExpr
6608 _n_expr2
= new_child
6616 redef meth visit_all
(v
: Visitor)
6618 if _n_expr
!= null then
6621 if _n_expr2
!= null then
6626 redef meth visit_all_reverse
(v
: Visitor)
6628 if _n_expr
!= null then
6631 if _n_expr2
!= null then
6637 redef meth n_expr
=(n
: PExpr)
6644 redef meth n_expr2
=(n
: PExpr)
6652 private init empty_init
do end
6660 if n_expr
!= null then
6661 n_expr
.parent
= self
6664 if n_expr2
!= null then
6665 n_expr2
.parent
= self
6669 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
6671 assert old_child
!= null
6672 if _n_expr
== old_child
then
6673 if new_child
!= null then
6674 new_child
.parent
= self
6675 assert new_child
isa PExpr
6682 if _n_expr2
== old_child
then
6683 if new_child
!= null then
6684 new_child
.parent
= self
6685 assert new_child
isa PExpr
6686 _n_expr2
= new_child
6694 redef meth visit_all
(v
: Visitor)
6696 if _n_expr
!= null then
6699 if _n_expr2
!= null then
6704 redef meth visit_all_reverse
(v
: Visitor)
6706 if _n_expr
!= null then
6709 if _n_expr2
!= null then
6715 redef meth n_expr
=(n
: PExpr)
6722 redef meth n_expr2
=(n
: PExpr)
6730 private init empty_init
do end
6738 if n_expr
!= null then
6739 n_expr
.parent
= self
6742 if n_expr2
!= null then
6743 n_expr2
.parent
= self
6747 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
6749 assert old_child
!= null
6750 if _n_expr
== old_child
then
6751 if new_child
!= null then
6752 new_child
.parent
= self
6753 assert new_child
isa PExpr
6760 if _n_expr2
== old_child
then
6761 if new_child
!= null then
6762 new_child
.parent
= self
6763 assert new_child
isa PExpr
6764 _n_expr2
= new_child
6772 redef meth visit_all
(v
: Visitor)
6774 if _n_expr
!= null then
6777 if _n_expr2
!= null then
6782 redef meth visit_all_reverse
(v
: Visitor)
6784 if _n_expr
!= null then
6787 if _n_expr2
!= null then
6792 redef class AIsaExpr
6793 redef meth n_expr
=(n
: PExpr)
6800 redef meth n_type
=(n
: PType)
6808 private init empty_init
do end
6810 init init_aisaexpr
(
6816 if n_expr
!= null then
6817 n_expr
.parent
= self
6820 if n_type
!= null then
6821 n_type
.parent
= self
6825 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
6827 assert old_child
!= null
6828 if _n_expr
== old_child
then
6829 if new_child
!= null then
6830 new_child
.parent
= self
6831 assert new_child
isa PExpr
6838 if _n_type
== old_child
then
6839 if new_child
!= null then
6840 new_child
.parent
= self
6841 assert new_child
isa PType
6850 redef meth visit_all
(v
: Visitor)
6852 if _n_expr
!= null then
6855 if _n_type
!= null then
6860 redef meth visit_all_reverse
(v
: Visitor)
6862 if _n_expr
!= null then
6865 if _n_type
!= null then
6870 redef class APlusExpr
6871 redef meth n_expr
=(n
: PExpr)
6878 redef meth n_expr2
=(n
: PExpr)
6886 private init empty_init
do end
6888 init init_aplusexpr
(
6894 if n_expr
!= null then
6895 n_expr
.parent
= self
6898 if n_expr2
!= null then
6899 n_expr2
.parent
= self
6903 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
6905 assert old_child
!= null
6906 if _n_expr
== old_child
then
6907 if new_child
!= null then
6908 new_child
.parent
= self
6909 assert new_child
isa PExpr
6916 if _n_expr2
== old_child
then
6917 if new_child
!= null then
6918 new_child
.parent
= self
6919 assert new_child
isa PExpr
6920 _n_expr2
= new_child
6928 redef meth visit_all
(v
: Visitor)
6930 if _n_expr
!= null then
6933 if _n_expr2
!= null then
6938 redef meth visit_all_reverse
(v
: Visitor)
6940 if _n_expr
!= null then
6943 if _n_expr2
!= null then
6948 redef class AMinusExpr
6949 redef meth n_expr
=(n
: PExpr)
6956 redef meth n_expr2
=(n
: PExpr)
6964 private init empty_init
do end
6966 init init_aminusexpr
(
6972 if n_expr
!= null then
6973 n_expr
.parent
= self
6976 if n_expr2
!= null then
6977 n_expr2
.parent
= self
6981 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
6983 assert old_child
!= null
6984 if _n_expr
== old_child
then
6985 if new_child
!= null then
6986 new_child
.parent
= self
6987 assert new_child
isa PExpr
6994 if _n_expr2
== old_child
then
6995 if new_child
!= null then
6996 new_child
.parent
= self
6997 assert new_child
isa PExpr
6998 _n_expr2
= new_child
7006 redef meth visit_all
(v
: Visitor)
7008 if _n_expr
!= null then
7011 if _n_expr2
!= null then
7016 redef meth visit_all_reverse
(v
: Visitor)
7018 if _n_expr
!= null then
7021 if _n_expr2
!= null then
7026 redef class AStarshipExpr
7027 redef meth n_expr
=(n
: PExpr)
7034 redef meth n_expr2
=(n
: PExpr)
7042 private init empty_init
do end
7044 init init_astarshipexpr
(
7050 if n_expr
!= null then
7051 n_expr
.parent
= self
7054 if n_expr2
!= null then
7055 n_expr2
.parent
= self
7059 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
7061 assert old_child
!= null
7062 if _n_expr
== old_child
then
7063 if new_child
!= null then
7064 new_child
.parent
= self
7065 assert new_child
isa PExpr
7072 if _n_expr2
== old_child
then
7073 if new_child
!= null then
7074 new_child
.parent
= self
7075 assert new_child
isa PExpr
7076 _n_expr2
= new_child
7084 redef meth visit_all
(v
: Visitor)
7086 if _n_expr
!= null then
7089 if _n_expr2
!= null then
7094 redef meth visit_all_reverse
(v
: Visitor)
7096 if _n_expr
!= null then
7099 if _n_expr2
!= null then
7104 redef class AStarExpr
7105 redef meth n_expr
=(n
: PExpr)
7112 redef meth n_expr2
=(n
: PExpr)
7120 private init empty_init
do end
7122 init init_astarexpr
(
7128 if n_expr
!= null then
7129 n_expr
.parent
= self
7132 if n_expr2
!= null then
7133 n_expr2
.parent
= self
7137 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
7139 assert old_child
!= null
7140 if _n_expr
== old_child
then
7141 if new_child
!= null then
7142 new_child
.parent
= self
7143 assert new_child
isa PExpr
7150 if _n_expr2
== old_child
then
7151 if new_child
!= null then
7152 new_child
.parent
= self
7153 assert new_child
isa PExpr
7154 _n_expr2
= new_child
7162 redef meth visit_all
(v
: Visitor)
7164 if _n_expr
!= null then
7167 if _n_expr2
!= null then
7172 redef meth visit_all_reverse
(v
: Visitor)
7174 if _n_expr
!= null then
7177 if _n_expr2
!= null then
7182 redef class ASlashExpr
7183 redef meth n_expr
=(n
: PExpr)
7190 redef meth n_expr2
=(n
: PExpr)
7198 private init empty_init
do end
7200 init init_aslashexpr
(
7206 if n_expr
!= null then
7207 n_expr
.parent
= self
7210 if n_expr2
!= null then
7211 n_expr2
.parent
= self
7215 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
7217 assert old_child
!= null
7218 if _n_expr
== old_child
then
7219 if new_child
!= null then
7220 new_child
.parent
= self
7221 assert new_child
isa PExpr
7228 if _n_expr2
== old_child
then
7229 if new_child
!= null then
7230 new_child
.parent
= self
7231 assert new_child
isa PExpr
7232 _n_expr2
= new_child
7240 redef meth visit_all
(v
: Visitor)
7242 if _n_expr
!= null then
7245 if _n_expr2
!= null then
7250 redef meth visit_all_reverse
(v
: Visitor)
7252 if _n_expr
!= null then
7255 if _n_expr2
!= null then
7260 redef class APercentExpr
7261 redef meth n_expr
=(n
: PExpr)
7268 redef meth n_expr2
=(n
: PExpr)
7276 private init empty_init
do end
7278 init init_apercentexpr
(
7284 if n_expr
!= null then
7285 n_expr
.parent
= self
7288 if n_expr2
!= null then
7289 n_expr2
.parent
= self
7293 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
7295 assert old_child
!= null
7296 if _n_expr
== old_child
then
7297 if new_child
!= null then
7298 new_child
.parent
= self
7299 assert new_child
isa PExpr
7306 if _n_expr2
== old_child
then
7307 if new_child
!= null then
7308 new_child
.parent
= self
7309 assert new_child
isa PExpr
7310 _n_expr2
= new_child
7318 redef meth visit_all
(v
: Visitor)
7320 if _n_expr
!= null then
7323 if _n_expr2
!= null then
7328 redef meth visit_all_reverse
(v
: Visitor)
7330 if _n_expr
!= null then
7333 if _n_expr2
!= null then
7338 redef class AUminusExpr
7339 redef meth n_minus
=(n
: TMinus)
7346 redef meth n_expr
=(n
: PExpr)
7354 private init empty_init
do end
7356 init init_auminusexpr
(
7362 if n_minus
!= null then
7363 n_minus
.parent
= self
7366 if n_expr
!= null then
7367 n_expr
.parent
= self
7371 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
7373 assert old_child
!= null
7374 if _n_minus
== old_child
then
7375 if new_child
!= null then
7376 new_child
.parent
= self
7377 assert new_child
isa TMinus
7378 _n_minus
= new_child
7384 if _n_expr
== old_child
then
7385 if new_child
!= null then
7386 new_child
.parent
= self
7387 assert new_child
isa PExpr
7396 redef meth visit_all
(v
: Visitor)
7398 if _n_minus
!= null then
7401 if _n_expr
!= null then
7406 redef meth visit_all_reverse
(v
: Visitor)
7408 if _n_minus
!= null then
7411 if _n_expr
!= null then
7416 redef class ANewExpr
7417 redef meth n_kwnew
=(n
: TKwnew)
7424 redef meth n_type
=(n
: PType)
7431 redef meth n_id
=(n
: TId)
7439 private init empty_init
do end
7441 init init_anewexpr
(
7445 n_args
: Array[Object] # Should be Array[PExpr]
7449 if n_kwnew
!= null then
7450 n_kwnew
.parent
= self
7453 if n_type
!= null then
7454 n_type
.parent
= self
7457 if n_id
!= null then
7460 _n_args
= new List[PExpr]
7468 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
7470 assert old_child
!= null
7471 if _n_kwnew
== old_child
then
7472 if new_child
!= null then
7473 new_child
.parent
= self
7474 assert new_child
isa TKwnew
7475 _n_kwnew
= new_child
7481 if _n_type
== old_child
then
7482 if new_child
!= null then
7483 new_child
.parent
= self
7484 assert new_child
isa PType
7491 if _n_id
== old_child
then
7492 if new_child
!= null then
7493 new_child
.parent
= self
7494 assert new_child
isa TId
7501 for i
in [0.._n_args
.length
[ do
7502 if _n_args
[i
] == old_child
then
7503 if new_child
!= null then
7504 assert new_child
isa PExpr
7505 _n_args
[i
] = new_child
7506 new_child
.parent
= self
7508 _n_args
.remove_at
(i
)
7515 redef meth visit_all
(v
: Visitor)
7517 if _n_kwnew
!= null then
7520 if _n_type
!= null then
7523 if _n_id
!= null then
7531 redef meth visit_all_reverse
(v
: Visitor)
7533 if _n_kwnew
!= null then
7536 if _n_type
!= null then
7539 if _n_id
!= null then
7543 var i
= _n_args
.length
7551 redef class AAttrExpr
7552 redef meth n_expr
=(n
: PExpr)
7559 redef meth n_id
=(n
: TAttrid)
7567 private init empty_init
do end
7569 init init_aattrexpr
(
7575 if n_expr
!= null then
7576 n_expr
.parent
= self
7579 if n_id
!= null then
7584 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
7586 assert old_child
!= null
7587 if _n_expr
== old_child
then
7588 if new_child
!= null then
7589 new_child
.parent
= self
7590 assert new_child
isa PExpr
7597 if _n_id
== old_child
then
7598 if new_child
!= null then
7599 new_child
.parent
= self
7600 assert new_child
isa TAttrid
7609 redef meth visit_all
(v
: Visitor)
7611 if _n_expr
!= null then
7614 if _n_id
!= null then
7619 redef meth visit_all_reverse
(v
: Visitor)
7621 if _n_expr
!= null then
7624 if _n_id
!= null then
7629 redef class AAttrAssignExpr
7630 redef meth n_expr
=(n
: PExpr)
7637 redef meth n_id
=(n
: TAttrid)
7644 redef meth n_assign
=(n
: TAssign)
7651 redef meth n_value
=(n
: PExpr)
7659 private init empty_init
do end
7661 init init_aattrassignexpr
(
7669 if n_expr
!= null then
7670 n_expr
.parent
= self
7673 if n_id
!= null then
7676 _n_assign
= n_assign
7677 if n_assign
!= null then
7678 n_assign
.parent
= self
7681 if n_value
!= null then
7682 n_value
.parent
= self
7686 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
7688 assert old_child
!= null
7689 if _n_expr
== old_child
then
7690 if new_child
!= null then
7691 new_child
.parent
= self
7692 assert new_child
isa PExpr
7699 if _n_id
== old_child
then
7700 if new_child
!= null then
7701 new_child
.parent
= self
7702 assert new_child
isa TAttrid
7709 if _n_assign
== old_child
then
7710 if new_child
!= null then
7711 new_child
.parent
= self
7712 assert new_child
isa TAssign
7713 _n_assign
= new_child
7719 if _n_value
== old_child
then
7720 if new_child
!= null then
7721 new_child
.parent
= self
7722 assert new_child
isa PExpr
7723 _n_value
= new_child
7731 redef meth visit_all
(v
: Visitor)
7733 if _n_expr
!= null then
7736 if _n_id
!= null then
7739 if _n_assign
!= null then
7742 if _n_value
!= null then
7747 redef meth visit_all_reverse
(v
: Visitor)
7749 if _n_expr
!= null then
7752 if _n_id
!= null then
7755 if _n_assign
!= null then
7758 if _n_value
!= null then
7763 redef class AAttrReassignExpr
7764 redef meth n_expr
=(n
: PExpr)
7771 redef meth n_id
=(n
: TAttrid)
7778 redef meth n_assign_op
=(n
: PAssignOp)
7785 redef meth n_value
=(n
: PExpr)
7793 private init empty_init
do end
7795 init init_aattrreassignexpr
(
7798 n_assign_op
: PAssignOp ,
7803 if n_expr
!= null then
7804 n_expr
.parent
= self
7807 if n_id
!= null then
7810 _n_assign_op
= n_assign_op
7811 if n_assign_op
!= null then
7812 n_assign_op
.parent
= self
7815 if n_value
!= null then
7816 n_value
.parent
= self
7820 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
7822 assert old_child
!= null
7823 if _n_expr
== old_child
then
7824 if new_child
!= null then
7825 new_child
.parent
= self
7826 assert new_child
isa PExpr
7833 if _n_id
== old_child
then
7834 if new_child
!= null then
7835 new_child
.parent
= self
7836 assert new_child
isa TAttrid
7843 if _n_assign_op
== old_child
then
7844 if new_child
!= null then
7845 new_child
.parent
= self
7846 assert new_child
isa PAssignOp
7847 _n_assign_op
= new_child
7853 if _n_value
== old_child
then
7854 if new_child
!= null then
7855 new_child
.parent
= self
7856 assert new_child
isa PExpr
7857 _n_value
= new_child
7865 redef meth visit_all
(v
: Visitor)
7867 if _n_expr
!= null then
7870 if _n_id
!= null then
7873 if _n_assign_op
!= null then
7874 v
.visit
(_n_assign_op
)
7876 if _n_value
!= null then
7881 redef meth visit_all_reverse
(v
: Visitor)
7883 if _n_expr
!= null then
7886 if _n_id
!= null then
7889 if _n_assign_op
!= null then
7890 v
.visit
(_n_assign_op
)
7892 if _n_value
!= null then
7897 redef class ACallExpr
7898 redef meth n_expr
=(n
: PExpr)
7905 redef meth n_id
=(n
: TId)
7913 private init empty_init
do end
7915 init init_acallexpr
(
7918 n_args
: Array[Object] # Should be Array[PExpr]
7922 if n_expr
!= null then
7923 n_expr
.parent
= self
7926 if n_id
!= null then
7929 _n_args
= new List[PExpr]
7937 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
7939 assert old_child
!= null
7940 if _n_expr
== old_child
then
7941 if new_child
!= null then
7942 new_child
.parent
= self
7943 assert new_child
isa PExpr
7950 if _n_id
== old_child
then
7951 if new_child
!= null then
7952 new_child
.parent
= self
7953 assert new_child
isa TId
7960 for i
in [0.._n_args
.length
[ do
7961 if _n_args
[i
] == old_child
then
7962 if new_child
!= null then
7963 assert new_child
isa PExpr
7964 _n_args
[i
] = new_child
7965 new_child
.parent
= self
7967 _n_args
.remove_at
(i
)
7974 redef meth visit_all
(v
: Visitor)
7976 if _n_expr
!= null then
7979 if _n_id
!= null then
7987 redef meth visit_all_reverse
(v
: Visitor)
7989 if _n_expr
!= null then
7992 if _n_id
!= null then
7996 var i
= _n_args
.length
8004 redef class ACallAssignExpr
8005 redef meth n_expr
=(n
: PExpr)
8012 redef meth n_id
=(n
: TId)
8019 redef meth n_assign
=(n
: TAssign)
8026 redef meth n_value
=(n
: PExpr)
8034 private init empty_init
do end
8036 init init_acallassignexpr
(
8039 n_args
: Array[Object] , # Should be Array[PExpr]
8045 if n_expr
!= null then
8046 n_expr
.parent
= self
8049 if n_id
!= null then
8052 _n_args
= new List[PExpr]
8058 _n_assign
= n_assign
8059 if n_assign
!= null then
8060 n_assign
.parent
= self
8063 if n_value
!= null then
8064 n_value
.parent
= self
8068 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
8070 assert old_child
!= null
8071 if _n_expr
== old_child
then
8072 if new_child
!= null then
8073 new_child
.parent
= self
8074 assert new_child
isa PExpr
8081 if _n_id
== old_child
then
8082 if new_child
!= null then
8083 new_child
.parent
= self
8084 assert new_child
isa TId
8091 for i
in [0.._n_args
.length
[ do
8092 if _n_args
[i
] == old_child
then
8093 if new_child
!= null then
8094 assert new_child
isa PExpr
8095 _n_args
[i
] = new_child
8096 new_child
.parent
= self
8098 _n_args
.remove_at
(i
)
8103 if _n_assign
== old_child
then
8104 if new_child
!= null then
8105 new_child
.parent
= self
8106 assert new_child
isa TAssign
8107 _n_assign
= new_child
8113 if _n_value
== old_child
then
8114 if new_child
!= null then
8115 new_child
.parent
= self
8116 assert new_child
isa PExpr
8117 _n_value
= new_child
8125 redef meth visit_all
(v
: Visitor)
8127 if _n_expr
!= null then
8130 if _n_id
!= null then
8136 if _n_assign
!= null then
8139 if _n_value
!= null then
8144 redef meth visit_all_reverse
(v
: Visitor)
8146 if _n_expr
!= null then
8149 if _n_id
!= null then
8153 var i
= _n_args
.length
8159 if _n_assign
!= null then
8162 if _n_value
!= null then
8167 redef class ACallReassignExpr
8168 redef meth n_expr
=(n
: PExpr)
8175 redef meth n_id
=(n
: TId)
8182 redef meth n_assign_op
=(n
: PAssignOp)
8189 redef meth n_value
=(n
: PExpr)
8197 private init empty_init
do end
8199 init init_acallreassignexpr
(
8202 n_args
: Array[Object] , # Should be Array[PExpr]
8203 n_assign_op
: PAssignOp ,
8208 if n_expr
!= null then
8209 n_expr
.parent
= self
8212 if n_id
!= null then
8215 _n_args
= new List[PExpr]
8221 _n_assign_op
= n_assign_op
8222 if n_assign_op
!= null then
8223 n_assign_op
.parent
= self
8226 if n_value
!= null then
8227 n_value
.parent
= self
8231 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
8233 assert old_child
!= null
8234 if _n_expr
== old_child
then
8235 if new_child
!= null then
8236 new_child
.parent
= self
8237 assert new_child
isa PExpr
8244 if _n_id
== old_child
then
8245 if new_child
!= null then
8246 new_child
.parent
= self
8247 assert new_child
isa TId
8254 for i
in [0.._n_args
.length
[ do
8255 if _n_args
[i
] == old_child
then
8256 if new_child
!= null then
8257 assert new_child
isa PExpr
8258 _n_args
[i
] = new_child
8259 new_child
.parent
= self
8261 _n_args
.remove_at
(i
)
8266 if _n_assign_op
== old_child
then
8267 if new_child
!= null then
8268 new_child
.parent
= self
8269 assert new_child
isa PAssignOp
8270 _n_assign_op
= new_child
8276 if _n_value
== old_child
then
8277 if new_child
!= null then
8278 new_child
.parent
= self
8279 assert new_child
isa PExpr
8280 _n_value
= new_child
8288 redef meth visit_all
(v
: Visitor)
8290 if _n_expr
!= null then
8293 if _n_id
!= null then
8299 if _n_assign_op
!= null then
8300 v
.visit
(_n_assign_op
)
8302 if _n_value
!= null then
8307 redef meth visit_all_reverse
(v
: Visitor)
8309 if _n_expr
!= null then
8312 if _n_id
!= null then
8316 var i
= _n_args
.length
8322 if _n_assign_op
!= null then
8323 v
.visit
(_n_assign_op
)
8325 if _n_value
!= null then
8330 redef class ASuperExpr
8331 redef meth n_qualified
=(n
: PQualified)
8338 redef meth n_kwsuper
=(n
: TKwsuper)
8346 private init empty_init
do end
8348 init init_asuperexpr
(
8349 n_qualified
: PQualified ,
8350 n_kwsuper
: TKwsuper ,
8351 n_args
: Array[Object] # Should be Array[PExpr]
8354 _n_qualified
= n_qualified
8355 if n_qualified
!= null then
8356 n_qualified
.parent
= self
8358 _n_kwsuper
= n_kwsuper
8359 if n_kwsuper
!= null then
8360 n_kwsuper
.parent
= self
8362 _n_args
= new List[PExpr]
8370 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
8372 assert old_child
!= null
8373 if _n_qualified
== old_child
then
8374 if new_child
!= null then
8375 new_child
.parent
= self
8376 assert new_child
isa PQualified
8377 _n_qualified
= new_child
8383 if _n_kwsuper
== old_child
then
8384 if new_child
!= null then
8385 new_child
.parent
= self
8386 assert new_child
isa TKwsuper
8387 _n_kwsuper
= new_child
8393 for i
in [0.._n_args
.length
[ do
8394 if _n_args
[i
] == old_child
then
8395 if new_child
!= null then
8396 assert new_child
isa PExpr
8397 _n_args
[i
] = new_child
8398 new_child
.parent
= self
8400 _n_args
.remove_at
(i
)
8407 redef meth visit_all
(v
: Visitor)
8409 if _n_qualified
!= null then
8410 v
.visit
(_n_qualified
)
8412 if _n_kwsuper
!= null then
8420 redef meth visit_all_reverse
(v
: Visitor)
8422 if _n_qualified
!= null then
8423 v
.visit
(_n_qualified
)
8425 if _n_kwsuper
!= null then
8429 var i
= _n_args
.length
8437 redef class AInitExpr
8438 redef meth n_expr
=(n
: PExpr)
8445 redef meth n_kwinit
=(n
: TKwinit)
8453 private init empty_init
do end
8455 init init_ainitexpr
(
8458 n_args
: Array[Object] # Should be Array[PExpr]
8462 if n_expr
!= null then
8463 n_expr
.parent
= self
8465 _n_kwinit
= n_kwinit
8466 if n_kwinit
!= null then
8467 n_kwinit
.parent
= self
8469 _n_args
= new List[PExpr]
8477 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
8479 assert old_child
!= null
8480 if _n_expr
== old_child
then
8481 if new_child
!= null then
8482 new_child
.parent
= self
8483 assert new_child
isa PExpr
8490 if _n_kwinit
== old_child
then
8491 if new_child
!= null then
8492 new_child
.parent
= self
8493 assert new_child
isa TKwinit
8494 _n_kwinit
= new_child
8500 for i
in [0.._n_args
.length
[ do
8501 if _n_args
[i
] == old_child
then
8502 if new_child
!= null then
8503 assert new_child
isa PExpr
8504 _n_args
[i
] = new_child
8505 new_child
.parent
= self
8507 _n_args
.remove_at
(i
)
8514 redef meth visit_all
(v
: Visitor)
8516 if _n_expr
!= null then
8519 if _n_kwinit
!= null then
8527 redef meth visit_all_reverse
(v
: Visitor)
8529 if _n_expr
!= null then
8532 if _n_kwinit
!= null then
8536 var i
= _n_args
.length
8544 redef class ABraExpr
8545 redef meth n_expr
=(n
: PExpr)
8553 private init empty_init
do end
8555 init init_abraexpr
(
8557 n_args
: Array[Object] # Should be Array[PExpr]
8561 if n_expr
!= null then
8562 n_expr
.parent
= self
8564 _n_args
= new List[PExpr]
8572 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
8574 assert old_child
!= null
8575 if _n_expr
== old_child
then
8576 if new_child
!= null then
8577 new_child
.parent
= self
8578 assert new_child
isa PExpr
8585 for i
in [0.._n_args
.length
[ do
8586 if _n_args
[i
] == old_child
then
8587 if new_child
!= null then
8588 assert new_child
isa PExpr
8589 _n_args
[i
] = new_child
8590 new_child
.parent
= self
8592 _n_args
.remove_at
(i
)
8599 redef meth visit_all
(v
: Visitor)
8601 if _n_expr
!= null then
8609 redef meth visit_all_reverse
(v
: Visitor)
8611 if _n_expr
!= null then
8615 var i
= _n_args
.length
8623 redef class ABraAssignExpr
8624 redef meth n_expr
=(n
: PExpr)
8631 redef meth n_assign
=(n
: TAssign)
8638 redef meth n_value
=(n
: PExpr)
8646 private init empty_init
do end
8648 init init_abraassignexpr
(
8650 n_args
: Array[Object] , # Should be Array[PExpr]
8656 if n_expr
!= null then
8657 n_expr
.parent
= self
8659 _n_args
= new List[PExpr]
8665 _n_assign
= n_assign
8666 if n_assign
!= null then
8667 n_assign
.parent
= self
8670 if n_value
!= null then
8671 n_value
.parent
= self
8675 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
8677 assert old_child
!= null
8678 if _n_expr
== old_child
then
8679 if new_child
!= null then
8680 new_child
.parent
= self
8681 assert new_child
isa PExpr
8688 for i
in [0.._n_args
.length
[ do
8689 if _n_args
[i
] == old_child
then
8690 if new_child
!= null then
8691 assert new_child
isa PExpr
8692 _n_args
[i
] = new_child
8693 new_child
.parent
= self
8695 _n_args
.remove_at
(i
)
8700 if _n_assign
== old_child
then
8701 if new_child
!= null then
8702 new_child
.parent
= self
8703 assert new_child
isa TAssign
8704 _n_assign
= new_child
8710 if _n_value
== old_child
then
8711 if new_child
!= null then
8712 new_child
.parent
= self
8713 assert new_child
isa PExpr
8714 _n_value
= new_child
8722 redef meth visit_all
(v
: Visitor)
8724 if _n_expr
!= null then
8730 if _n_assign
!= null then
8733 if _n_value
!= null then
8738 redef meth visit_all_reverse
(v
: Visitor)
8740 if _n_expr
!= null then
8744 var i
= _n_args
.length
8750 if _n_assign
!= null then
8753 if _n_value
!= null then
8758 redef class ABraReassignExpr
8759 redef meth n_expr
=(n
: PExpr)
8766 redef meth n_assign_op
=(n
: PAssignOp)
8773 redef meth n_value
=(n
: PExpr)
8781 private init empty_init
do end
8783 init init_abrareassignexpr
(
8785 n_args
: Array[Object] , # Should be Array[PExpr]
8786 n_assign_op
: PAssignOp ,
8791 if n_expr
!= null then
8792 n_expr
.parent
= self
8794 _n_args
= new List[PExpr]
8800 _n_assign_op
= n_assign_op
8801 if n_assign_op
!= null then
8802 n_assign_op
.parent
= self
8805 if n_value
!= null then
8806 n_value
.parent
= self
8810 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
8812 assert old_child
!= null
8813 if _n_expr
== old_child
then
8814 if new_child
!= null then
8815 new_child
.parent
= self
8816 assert new_child
isa PExpr
8823 for i
in [0.._n_args
.length
[ do
8824 if _n_args
[i
] == old_child
then
8825 if new_child
!= null then
8826 assert new_child
isa PExpr
8827 _n_args
[i
] = new_child
8828 new_child
.parent
= self
8830 _n_args
.remove_at
(i
)
8835 if _n_assign_op
== old_child
then
8836 if new_child
!= null then
8837 new_child
.parent
= self
8838 assert new_child
isa PAssignOp
8839 _n_assign_op
= new_child
8845 if _n_value
== old_child
then
8846 if new_child
!= null then
8847 new_child
.parent
= self
8848 assert new_child
isa PExpr
8849 _n_value
= new_child
8857 redef meth visit_all
(v
: Visitor)
8859 if _n_expr
!= null then
8865 if _n_assign_op
!= null then
8866 v
.visit
(_n_assign_op
)
8868 if _n_value
!= null then
8873 redef meth visit_all_reverse
(v
: Visitor)
8875 if _n_expr
!= null then
8879 var i
= _n_args
.length
8885 if _n_assign_op
!= null then
8886 v
.visit
(_n_assign_op
)
8888 if _n_value
!= null then
8893 redef class AVarExpr
8894 redef meth n_id
=(n
: TId)
8902 private init empty_init
do end
8904 init init_avarexpr
(
8909 if n_id
!= null then
8914 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
8916 assert old_child
!= null
8917 if _n_id
== old_child
then
8918 if new_child
!= null then
8919 new_child
.parent
= self
8920 assert new_child
isa TId
8929 redef meth visit_all
(v
: Visitor)
8931 if _n_id
!= null then
8936 redef meth visit_all_reverse
(v
: Visitor)
8938 if _n_id
!= null then
8943 redef class AVarAssignExpr
8944 redef meth n_id
=(n
: TId)
8951 redef meth n_assign
=(n
: TAssign)
8958 redef meth n_value
=(n
: PExpr)
8966 private init empty_init
do end
8968 init init_avarassignexpr
(
8975 if n_id
!= null then
8978 _n_assign
= n_assign
8979 if n_assign
!= null then
8980 n_assign
.parent
= self
8983 if n_value
!= null then
8984 n_value
.parent
= self
8988 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
8990 assert old_child
!= null
8991 if _n_id
== old_child
then
8992 if new_child
!= null then
8993 new_child
.parent
= self
8994 assert new_child
isa TId
9001 if _n_assign
== old_child
then
9002 if new_child
!= null then
9003 new_child
.parent
= self
9004 assert new_child
isa TAssign
9005 _n_assign
= new_child
9011 if _n_value
== old_child
then
9012 if new_child
!= null then
9013 new_child
.parent
= self
9014 assert new_child
isa PExpr
9015 _n_value
= new_child
9023 redef meth visit_all
(v
: Visitor)
9025 if _n_id
!= null then
9028 if _n_assign
!= null then
9031 if _n_value
!= null then
9036 redef meth visit_all_reverse
(v
: Visitor)
9038 if _n_id
!= null then
9041 if _n_assign
!= null then
9044 if _n_value
!= null then
9049 redef class AVarReassignExpr
9050 redef meth n_id
=(n
: TId)
9057 redef meth n_assign_op
=(n
: PAssignOp)
9064 redef meth n_value
=(n
: PExpr)
9072 private init empty_init
do end
9074 init init_avarreassignexpr
(
9076 n_assign_op
: PAssignOp ,
9081 if n_id
!= null then
9084 _n_assign_op
= n_assign_op
9085 if n_assign_op
!= null then
9086 n_assign_op
.parent
= self
9089 if n_value
!= null then
9090 n_value
.parent
= self
9094 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9096 assert old_child
!= null
9097 if _n_id
== old_child
then
9098 if new_child
!= null then
9099 new_child
.parent
= self
9100 assert new_child
isa TId
9107 if _n_assign_op
== old_child
then
9108 if new_child
!= null then
9109 new_child
.parent
= self
9110 assert new_child
isa PAssignOp
9111 _n_assign_op
= new_child
9117 if _n_value
== old_child
then
9118 if new_child
!= null then
9119 new_child
.parent
= self
9120 assert new_child
isa PExpr
9121 _n_value
= new_child
9129 redef meth visit_all
(v
: Visitor)
9131 if _n_id
!= null then
9134 if _n_assign_op
!= null then
9135 v
.visit
(_n_assign_op
)
9137 if _n_value
!= null then
9142 redef meth visit_all_reverse
(v
: Visitor)
9144 if _n_id
!= null then
9147 if _n_assign_op
!= null then
9148 v
.visit
(_n_assign_op
)
9150 if _n_value
!= null then
9155 redef class ARangeExpr
9156 redef meth n_expr
=(n
: PExpr)
9163 redef meth n_expr2
=(n
: PExpr)
9171 private init empty_init
do end
9173 init init_arangeexpr
(
9179 if n_expr
!= null then
9180 n_expr
.parent
= self
9183 if n_expr2
!= null then
9184 n_expr2
.parent
= self
9188 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9190 assert old_child
!= null
9191 if _n_expr
== old_child
then
9192 if new_child
!= null then
9193 new_child
.parent
= self
9194 assert new_child
isa PExpr
9201 if _n_expr2
== old_child
then
9202 if new_child
!= null then
9203 new_child
.parent
= self
9204 assert new_child
isa PExpr
9205 _n_expr2
= new_child
9213 redef meth visit_all
(v
: Visitor)
9215 if _n_expr
!= null then
9218 if _n_expr2
!= null then
9223 redef meth visit_all_reverse
(v
: Visitor)
9225 if _n_expr
!= null then
9228 if _n_expr2
!= null then
9233 redef class ACrangeExpr
9234 redef meth n_expr
=(n
: PExpr)
9241 redef meth n_expr2
=(n
: PExpr)
9249 private init empty_init
do end
9251 init init_acrangeexpr
(
9257 if n_expr
!= null then
9258 n_expr
.parent
= self
9261 if n_expr2
!= null then
9262 n_expr2
.parent
= self
9266 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9268 assert old_child
!= null
9269 if _n_expr
== old_child
then
9270 if new_child
!= null then
9271 new_child
.parent
= self
9272 assert new_child
isa PExpr
9279 if _n_expr2
== old_child
then
9280 if new_child
!= null then
9281 new_child
.parent
= self
9282 assert new_child
isa PExpr
9283 _n_expr2
= new_child
9291 redef meth visit_all
(v
: Visitor)
9293 if _n_expr
!= null then
9296 if _n_expr2
!= null then
9301 redef meth visit_all_reverse
(v
: Visitor)
9303 if _n_expr
!= null then
9306 if _n_expr2
!= null then
9311 redef class AOrangeExpr
9312 redef meth n_expr
=(n
: PExpr)
9319 redef meth n_expr2
=(n
: PExpr)
9327 private init empty_init
do end
9329 init init_aorangeexpr
(
9335 if n_expr
!= null then
9336 n_expr
.parent
= self
9339 if n_expr2
!= null then
9340 n_expr2
.parent
= self
9344 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9346 assert old_child
!= null
9347 if _n_expr
== old_child
then
9348 if new_child
!= null then
9349 new_child
.parent
= self
9350 assert new_child
isa PExpr
9357 if _n_expr2
== old_child
then
9358 if new_child
!= null then
9359 new_child
.parent
= self
9360 assert new_child
isa PExpr
9361 _n_expr2
= new_child
9369 redef meth visit_all
(v
: Visitor)
9371 if _n_expr
!= null then
9374 if _n_expr2
!= null then
9379 redef meth visit_all_reverse
(v
: Visitor)
9381 if _n_expr
!= null then
9384 if _n_expr2
!= null then
9389 redef class AArrayExpr
9391 private init empty_init
do end
9393 init init_aarrayexpr
(
9394 n_exprs
: Array[Object] # Should be Array[PExpr]
9397 _n_exprs
= new List[PExpr]
9405 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9407 assert old_child
!= null
9408 for i
in [0.._n_exprs
.length
[ do
9409 if _n_exprs
[i
] == old_child
then
9410 if new_child
!= null then
9411 assert new_child
isa PExpr
9412 _n_exprs
[i
] = new_child
9413 new_child
.parent
= self
9415 _n_exprs
.remove_at
(i
)
9422 redef meth visit_all
(v
: Visitor)
9424 for n
in _n_exprs
do
9429 redef meth visit_all_reverse
(v
: Visitor)
9432 var i
= _n_exprs
.length
9434 v
.visit
(_n_exprs
[i
])
9440 redef class ASelfExpr
9441 redef meth n_kwself
=(n
: TKwself)
9449 private init empty_init
do end
9451 init init_aselfexpr
(
9455 _n_kwself
= n_kwself
9456 if n_kwself
!= null then
9457 n_kwself
.parent
= self
9461 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9463 assert old_child
!= null
9464 if _n_kwself
== old_child
then
9465 if new_child
!= null then
9466 new_child
.parent
= self
9467 assert new_child
isa TKwself
9468 _n_kwself
= new_child
9476 redef meth visit_all
(v
: Visitor)
9478 if _n_kwself
!= null then
9483 redef meth visit_all_reverse
(v
: Visitor)
9485 if _n_kwself
!= null then
9490 redef class AImplicitSelfExpr
9492 private init empty_init
do end
9494 init init_aimplicitselfexpr
9498 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9500 assert old_child
!= null
9503 redef meth visit_all
(v
: Visitor)
9507 redef meth visit_all_reverse
(v
: Visitor)
9511 redef class ATrueExpr
9512 redef meth n_kwtrue
=(n
: TKwtrue)
9520 private init empty_init
do end
9522 init init_atrueexpr
(
9526 _n_kwtrue
= n_kwtrue
9527 if n_kwtrue
!= null then
9528 n_kwtrue
.parent
= self
9532 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9534 assert old_child
!= null
9535 if _n_kwtrue
== old_child
then
9536 if new_child
!= null then
9537 new_child
.parent
= self
9538 assert new_child
isa TKwtrue
9539 _n_kwtrue
= new_child
9547 redef meth visit_all
(v
: Visitor)
9549 if _n_kwtrue
!= null then
9554 redef meth visit_all_reverse
(v
: Visitor)
9556 if _n_kwtrue
!= null then
9561 redef class AFalseExpr
9562 redef meth n_kwfalse
=(n
: TKwfalse)
9570 private init empty_init
do end
9572 init init_afalseexpr
(
9576 _n_kwfalse
= n_kwfalse
9577 if n_kwfalse
!= null then
9578 n_kwfalse
.parent
= self
9582 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9584 assert old_child
!= null
9585 if _n_kwfalse
== old_child
then
9586 if new_child
!= null then
9587 new_child
.parent
= self
9588 assert new_child
isa TKwfalse
9589 _n_kwfalse
= new_child
9597 redef meth visit_all
(v
: Visitor)
9599 if _n_kwfalse
!= null then
9604 redef meth visit_all_reverse
(v
: Visitor)
9606 if _n_kwfalse
!= null then
9611 redef class ANullExpr
9612 redef meth n_kwnull
=(n
: TKwnull)
9620 private init empty_init
do end
9622 init init_anullexpr
(
9626 _n_kwnull
= n_kwnull
9627 if n_kwnull
!= null then
9628 n_kwnull
.parent
= self
9632 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9634 assert old_child
!= null
9635 if _n_kwnull
== old_child
then
9636 if new_child
!= null then
9637 new_child
.parent
= self
9638 assert new_child
isa TKwnull
9639 _n_kwnull
= new_child
9647 redef meth visit_all
(v
: Visitor)
9649 if _n_kwnull
!= null then
9654 redef meth visit_all_reverse
(v
: Visitor)
9656 if _n_kwnull
!= null then
9661 redef class AIntExpr
9662 redef meth n_number
=(n
: TNumber)
9670 private init empty_init
do end
9672 init init_aintexpr
(
9676 _n_number
= n_number
9677 if n_number
!= null then
9678 n_number
.parent
= self
9682 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9684 assert old_child
!= null
9685 if _n_number
== old_child
then
9686 if new_child
!= null then
9687 new_child
.parent
= self
9688 assert new_child
isa TNumber
9689 _n_number
= new_child
9697 redef meth visit_all
(v
: Visitor)
9699 if _n_number
!= null then
9704 redef meth visit_all_reverse
(v
: Visitor)
9706 if _n_number
!= null then
9711 redef class AFloatExpr
9712 redef meth n_float
=(n
: TFloat)
9720 private init empty_init
do end
9722 init init_afloatexpr
(
9727 if n_float
!= null then
9728 n_float
.parent
= self
9732 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9734 assert old_child
!= null
9735 if _n_float
== old_child
then
9736 if new_child
!= null then
9737 new_child
.parent
= self
9738 assert new_child
isa TFloat
9739 _n_float
= new_child
9747 redef meth visit_all
(v
: Visitor)
9749 if _n_float
!= null then
9754 redef meth visit_all_reverse
(v
: Visitor)
9756 if _n_float
!= null then
9761 redef class ACharExpr
9762 redef meth n_char
=(n
: TChar)
9770 private init empty_init
do end
9772 init init_acharexpr
(
9777 if n_char
!= null then
9778 n_char
.parent
= self
9782 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9784 assert old_child
!= null
9785 if _n_char
== old_child
then
9786 if new_child
!= null then
9787 new_child
.parent
= self
9788 assert new_child
isa TChar
9797 redef meth visit_all
(v
: Visitor)
9799 if _n_char
!= null then
9804 redef meth visit_all_reverse
(v
: Visitor)
9806 if _n_char
!= null then
9811 redef class AStringExpr
9812 redef meth n_string
=(n
: TString)
9820 private init empty_init
do end
9822 init init_astringexpr
(
9826 _n_string
= n_string
9827 if n_string
!= null then
9828 n_string
.parent
= self
9832 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9834 assert old_child
!= null
9835 if _n_string
== old_child
then
9836 if new_child
!= null then
9837 new_child
.parent
= self
9838 assert new_child
isa TString
9839 _n_string
= new_child
9847 redef meth visit_all
(v
: Visitor)
9849 if _n_string
!= null then
9854 redef meth visit_all_reverse
(v
: Visitor)
9856 if _n_string
!= null then
9861 redef class AStartStringExpr
9862 redef meth n_string
=(n
: TStartString)
9870 private init empty_init
do end
9872 init init_astartstringexpr
(
9873 n_string
: TStartString
9876 _n_string
= n_string
9877 if n_string
!= null then
9878 n_string
.parent
= self
9882 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9884 assert old_child
!= null
9885 if _n_string
== old_child
then
9886 if new_child
!= null then
9887 new_child
.parent
= self
9888 assert new_child
isa TStartString
9889 _n_string
= new_child
9897 redef meth visit_all
(v
: Visitor)
9899 if _n_string
!= null then
9904 redef meth visit_all_reverse
(v
: Visitor)
9906 if _n_string
!= null then
9911 redef class AMidStringExpr
9912 redef meth n_string
=(n
: TMidString)
9920 private init empty_init
do end
9922 init init_amidstringexpr
(
9923 n_string
: TMidString
9926 _n_string
= n_string
9927 if n_string
!= null then
9928 n_string
.parent
= self
9932 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9934 assert old_child
!= null
9935 if _n_string
== old_child
then
9936 if new_child
!= null then
9937 new_child
.parent
= self
9938 assert new_child
isa TMidString
9939 _n_string
= new_child
9947 redef meth visit_all
(v
: Visitor)
9949 if _n_string
!= null then
9954 redef meth visit_all_reverse
(v
: Visitor)
9956 if _n_string
!= null then
9961 redef class AEndStringExpr
9962 redef meth n_string
=(n
: TEndString)
9970 private init empty_init
do end
9972 init init_aendstringexpr
(
9973 n_string
: TEndString
9976 _n_string
= n_string
9977 if n_string
!= null then
9978 n_string
.parent
= self
9982 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9984 assert old_child
!= null
9985 if _n_string
== old_child
then
9986 if new_child
!= null then
9987 new_child
.parent
= self
9988 assert new_child
isa TEndString
9989 _n_string
= new_child
9997 redef meth visit_all
(v
: Visitor)
9999 if _n_string
!= null then
10004 redef meth visit_all_reverse
(v
: Visitor)
10006 if _n_string
!= null then
10011 redef class ASuperstringExpr
10013 private init empty_init
do end
10015 init init_asuperstringexpr
(
10016 n_exprs
: Array[Object] # Should be Array[PExpr]
10019 _n_exprs
= new List[PExpr]
10020 for n
in n_exprs
do
10027 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
10029 assert old_child
!= null
10030 for i
in [0.._n_exprs
.length
[ do
10031 if _n_exprs
[i
] == old_child
then
10032 if new_child
!= null then
10033 assert new_child
isa PExpr
10034 _n_exprs
[i
] = new_child
10035 new_child
.parent
= self
10037 _n_exprs
.remove_at
(i
)
10044 redef meth visit_all
(v
: Visitor)
10046 for n
in _n_exprs
do
10051 redef meth visit_all_reverse
(v
: Visitor)
10054 var i
= _n_exprs
.length
10056 v
.visit
(_n_exprs
[i
])
10062 redef class AParExpr
10063 redef meth n_expr
=(n
: PExpr)
10071 private init empty_init
do end
10073 init init_aparexpr
(
10078 if n_expr
!= null then
10079 n_expr
.parent
= self
10083 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
10085 assert old_child
!= null
10086 if _n_expr
== old_child
then
10087 if new_child
!= null then
10088 new_child
.parent
= self
10089 assert new_child
isa PExpr
10090 _n_expr
= new_child
10098 redef meth visit_all
(v
: Visitor)
10100 if _n_expr
!= null then
10105 redef meth visit_all_reverse
(v
: Visitor)
10107 if _n_expr
!= null then
10112 redef class AAsCastExpr
10113 redef meth n_expr
=(n
: PExpr)
10120 redef meth n_kwas
=(n
: TKwas)
10127 redef meth n_type
=(n
: PType)
10135 private init empty_init
do end
10137 init init_aascastexpr
(
10144 if n_expr
!= null then
10145 n_expr
.parent
= self
10148 if n_kwas
!= null then
10149 n_kwas
.parent
= self
10152 if n_type
!= null then
10153 n_type
.parent
= self
10157 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
10159 assert old_child
!= null
10160 if _n_expr
== old_child
then
10161 if new_child
!= null then
10162 new_child
.parent
= self
10163 assert new_child
isa PExpr
10164 _n_expr
= new_child
10170 if _n_kwas
== old_child
then
10171 if new_child
!= null then
10172 new_child
.parent
= self
10173 assert new_child
isa TKwas
10174 _n_kwas
= new_child
10180 if _n_type
== old_child
then
10181 if new_child
!= null then
10182 new_child
.parent
= self
10183 assert new_child
isa PType
10184 _n_type
= new_child
10192 redef meth visit_all
(v
: Visitor)
10194 if _n_expr
!= null then
10197 if _n_kwas
!= null then
10200 if _n_type
!= null then
10205 redef meth visit_all_reverse
(v
: Visitor)
10207 if _n_expr
!= null then
10210 if _n_kwas
!= null then
10213 if _n_type
!= null then
10218 redef class APlusAssignOp
10219 redef meth n_pluseq
=(n
: TPluseq)
10227 private init empty_init
do end
10229 init init_aplusassignop
(
10233 _n_pluseq
= n_pluseq
10234 if n_pluseq
!= null then
10235 n_pluseq
.parent
= self
10239 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
10241 assert old_child
!= null
10242 if _n_pluseq
== old_child
then
10243 if new_child
!= null then
10244 new_child
.parent
= self
10245 assert new_child
isa TPluseq
10246 _n_pluseq
= new_child
10254 redef meth visit_all
(v
: Visitor)
10256 if _n_pluseq
!= null then
10261 redef meth visit_all_reverse
(v
: Visitor)
10263 if _n_pluseq
!= null then
10268 redef class AMinusAssignOp
10269 redef meth n_minuseq
=(n
: TMinuseq)
10277 private init empty_init
do end
10279 init init_aminusassignop
(
10280 n_minuseq
: TMinuseq
10283 _n_minuseq
= n_minuseq
10284 if n_minuseq
!= null then
10285 n_minuseq
.parent
= self
10289 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
10291 assert old_child
!= null
10292 if _n_minuseq
== old_child
then
10293 if new_child
!= null then
10294 new_child
.parent
= self
10295 assert new_child
isa TMinuseq
10296 _n_minuseq
= new_child
10304 redef meth visit_all
(v
: Visitor)
10306 if _n_minuseq
!= null then
10307 v
.visit
(_n_minuseq
)
10311 redef meth visit_all_reverse
(v
: Visitor)
10313 if _n_minuseq
!= null then
10314 v
.visit
(_n_minuseq
)
10318 redef class AQualified
10319 redef meth n_classid
=(n
: TClassid)
10327 private init empty_init
do end
10329 init init_aqualified
(
10330 n_id
: Array[Object] , # Should be Array[TId]
10331 n_classid
: TClassid
10334 _n_id
= new List[TId]
10340 _n_classid
= n_classid
10341 if n_classid
!= null then
10342 n_classid
.parent
= self
10346 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
10348 assert old_child
!= null
10349 for i
in [0.._n_id
.length
[ do
10350 if _n_id
[i
] == old_child
then
10351 if new_child
!= null then
10352 assert new_child
isa TId
10353 _n_id
[i
] = new_child
10354 new_child
.parent
= self
10361 if _n_classid
== old_child
then
10362 if new_child
!= null then
10363 new_child
.parent
= self
10364 assert new_child
isa TClassid
10365 _n_classid
= new_child
10373 redef meth visit_all
(v
: Visitor)
10378 if _n_classid
!= null then
10379 v
.visit
(_n_classid
)
10383 redef meth visit_all_reverse
(v
: Visitor)
10386 var i
= _n_id
.length
10392 if _n_classid
!= null then
10393 v
.visit
(_n_classid
)
10399 private init empty_init
do end
10402 n_comment
: Array[Object] # Should be Array[TComment]
10405 _n_comment
= new List[TComment]
10406 for n
in n_comment
do
10407 assert n
isa TComment
10413 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
10415 assert old_child
!= null
10416 for i
in [0.._n_comment
.length
[ do
10417 if _n_comment
[i
] == old_child
then
10418 if new_child
!= null then
10419 assert new_child
isa TComment
10420 _n_comment
[i
] = new_child
10421 new_child
.parent
= self
10423 _n_comment
.remove_at
(i
)
10430 redef meth visit_all
(v
: Visitor)
10432 for n
in _n_comment
do
10437 redef meth visit_all_reverse
(v
: Visitor)
10440 var i
= _n_comment
.length
10442 v
.visit
(_n_comment
[i
])
10458 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
10460 assert old_child
!= null
10461 if _n_base
== old_child
then
10462 if new_child
== null then
10464 new_child
.parent
= self
10465 assert new_child
isa PModule
10466 _n_base
= new_child
10468 old_child
.parent
= null
10473 redef meth visit_all
(v
: Visitor)
10475 if _n_base
!= null then
10480 redef meth visit_all_reverse
(v
: Visitor)
10482 if _n_base
!= null then