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 # Debug method: output a message prefixed with the location.
41 meth printl
(str
: String)
43 print
("{locate}: {str}\n")
48 redef meth visit_all
(v
: Visitor) do end
49 redef meth visit_all_reverse
(v
: Visitor) do end
50 redef meth replace_child
(old_child
: PNode, new_child
: PNode) do end
52 redef meth locate
: String
54 return "{filename}:{line},{pos}"
59 # The first token of the production node
60 readable writable attr _first_token
: Token
62 # The last token of the production node
63 readable writable attr _last_token
: Token
65 redef meth locate
: String
67 if first_token
== null then
70 var lastpos
= last_token
.pos
+ last_token
.text
.length
- 1
71 if first_token
.line
== last_token
.line
then
72 return "{first_token.locate}--{lastpos}"
74 return "{first_token.locate}--{last_token.line}:{lastpos}"
78 redef meth replace_with
(n
: PNode)
82 n
.first_token
= first_token
83 n
.last_token
= last_token
87 # Abstract standard visitor
89 # Ask the visitor to visit a given node.
90 # Usually automatically called by visit_all* methods.
91 # Concrete visitors should redefine this method.
92 meth visit
(e
: PNode) is abstract
96 redef meth n_packagedecl
=(n
: PPackagedecl)
104 private init empty_init
do end
107 n_packagedecl
: PPackagedecl ,
108 n_imports
: Array[Object] , # Should be Array[PImport]
109 n_classdefs
: Array[Object] # Should be Array[PClassdef]
112 _n_packagedecl
= n_packagedecl
113 if n_packagedecl
!= null then
114 n_packagedecl
.parent
= self
116 _n_imports
= new List[PImport]
117 for n
in n_imports
do
122 _n_classdefs
= new List[PClassdef]
123 for n
in n_classdefs
do
124 assert n
isa PClassdef
130 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
132 assert old_child
!= null
133 if _n_packagedecl
== old_child
then
134 if new_child
!= null then
135 new_child
.parent
= self
136 assert new_child
isa PPackagedecl
137 _n_packagedecl
= new_child
139 _n_packagedecl
= null
143 for i
in [0.._n_imports
.length
[ do
144 if _n_imports
[i
] == old_child
then
145 if new_child
!= null then
146 assert new_child
isa PImport
147 _n_imports
[i
] = new_child
148 new_child
.parent
= self
150 _n_imports
.remove_at
(i
)
155 for i
in [0.._n_classdefs
.length
[ do
156 if _n_classdefs
[i
] == old_child
then
157 if new_child
!= null then
158 assert new_child
isa PClassdef
159 _n_classdefs
[i
] = new_child
160 new_child
.parent
= self
162 _n_classdefs
.remove_at
(i
)
169 redef meth visit_all
(v
: Visitor)
171 if _n_packagedecl
!= null then
172 v
.visit
(_n_packagedecl
)
174 for n
in _n_imports
do
177 for n
in _n_classdefs
do
182 redef meth visit_all_reverse
(v
: Visitor)
184 if _n_packagedecl
!= null then
185 v
.visit
(_n_packagedecl
)
188 var i
= _n_imports
.length
190 v
.visit
(_n_imports
[i
])
195 var i
= _n_classdefs
.length
197 v
.visit
(_n_classdefs
[i
])
203 redef class APackagedecl
204 redef meth n_doc
=(n
: PDoc)
211 redef meth n_kwpackage
=(n
: TKwpackage)
218 redef meth n_id
=(n
: TId)
226 private init empty_init
do end
228 init init_apackagedecl
(
230 n_kwpackage
: TKwpackage ,
235 if n_doc
!= null then
238 _n_kwpackage
= n_kwpackage
239 if n_kwpackage
!= null then
240 n_kwpackage
.parent
= self
248 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
250 assert old_child
!= null
251 if _n_doc
== old_child
then
252 if new_child
!= null then
253 new_child
.parent
= self
254 assert new_child
isa PDoc
261 if _n_kwpackage
== old_child
then
262 if new_child
!= null then
263 new_child
.parent
= self
264 assert new_child
isa TKwpackage
265 _n_kwpackage
= new_child
271 if _n_id
== old_child
then
272 if new_child
!= null then
273 new_child
.parent
= self
274 assert new_child
isa TId
283 redef meth visit_all
(v
: Visitor)
285 if _n_doc
!= null then
288 if _n_kwpackage
!= null then
289 v
.visit
(_n_kwpackage
)
291 if _n_id
!= null then
296 redef meth visit_all_reverse
(v
: Visitor)
298 if _n_doc
!= null then
301 if _n_kwpackage
!= null then
302 v
.visit
(_n_kwpackage
)
304 if _n_id
!= null then
310 redef meth n_visibility
=(n
: PVisibility)
317 redef meth n_kwimport
=(n
: TKwimport)
324 redef meth n_id
=(n
: TId)
332 private init empty_init
do end
335 n_visibility
: PVisibility ,
336 n_kwimport
: TKwimport ,
340 _n_visibility
= n_visibility
341 if n_visibility
!= null then
342 n_visibility
.parent
= self
344 _n_kwimport
= n_kwimport
345 if n_kwimport
!= null then
346 n_kwimport
.parent
= self
354 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
356 assert old_child
!= null
357 if _n_visibility
== old_child
then
358 if new_child
!= null then
359 new_child
.parent
= self
360 assert new_child
isa PVisibility
361 _n_visibility
= new_child
367 if _n_kwimport
== old_child
then
368 if new_child
!= null then
369 new_child
.parent
= self
370 assert new_child
isa TKwimport
371 _n_kwimport
= new_child
377 if _n_id
== old_child
then
378 if new_child
!= null then
379 new_child
.parent
= self
380 assert new_child
isa TId
389 redef meth visit_all
(v
: Visitor)
391 if _n_visibility
!= null then
392 v
.visit
(_n_visibility
)
394 if _n_kwimport
!= null then
397 if _n_id
!= null then
402 redef meth visit_all_reverse
(v
: Visitor)
404 if _n_visibility
!= null then
405 v
.visit
(_n_visibility
)
407 if _n_kwimport
!= null then
410 if _n_id
!= null then
415 redef class ANoImport
416 redef meth n_visibility
=(n
: PVisibility)
423 redef meth n_kwimport
=(n
: TKwimport)
430 redef meth n_kwend
=(n
: TKwend)
438 private init empty_init
do end
440 init init_anoimport
(
441 n_visibility
: PVisibility ,
442 n_kwimport
: TKwimport ,
446 _n_visibility
= n_visibility
447 if n_visibility
!= null then
448 n_visibility
.parent
= self
450 _n_kwimport
= n_kwimport
451 if n_kwimport
!= null then
452 n_kwimport
.parent
= self
455 if n_kwend
!= null then
456 n_kwend
.parent
= self
460 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
462 assert old_child
!= null
463 if _n_visibility
== old_child
then
464 if new_child
!= null then
465 new_child
.parent
= self
466 assert new_child
isa PVisibility
467 _n_visibility
= new_child
473 if _n_kwimport
== old_child
then
474 if new_child
!= null then
475 new_child
.parent
= self
476 assert new_child
isa TKwimport
477 _n_kwimport
= new_child
483 if _n_kwend
== old_child
then
484 if new_child
!= null then
485 new_child
.parent
= self
486 assert new_child
isa TKwend
495 redef meth visit_all
(v
: Visitor)
497 if _n_visibility
!= null then
498 v
.visit
(_n_visibility
)
500 if _n_kwimport
!= null then
503 if _n_kwend
!= null then
508 redef meth visit_all_reverse
(v
: Visitor)
510 if _n_visibility
!= null then
511 v
.visit
(_n_visibility
)
513 if _n_kwimport
!= null then
516 if _n_kwend
!= null then
521 redef class APublicVisibility
523 private init empty_init
do end
525 init init_apublicvisibility
529 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
531 assert old_child
!= null
534 redef meth visit_all
(v
: Visitor)
538 redef meth visit_all_reverse
(v
: Visitor)
542 redef class APrivateVisibility
543 redef meth n_kwprivate
=(n
: TKwprivate)
551 private init empty_init
do end
553 init init_aprivatevisibility
(
554 n_kwprivate
: TKwprivate
557 _n_kwprivate
= n_kwprivate
558 if n_kwprivate
!= null then
559 n_kwprivate
.parent
= self
563 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
565 assert old_child
!= null
566 if _n_kwprivate
== old_child
then
567 if new_child
!= null then
568 new_child
.parent
= self
569 assert new_child
isa TKwprivate
570 _n_kwprivate
= new_child
578 redef meth visit_all
(v
: Visitor)
580 if _n_kwprivate
!= null then
581 v
.visit
(_n_kwprivate
)
585 redef meth visit_all_reverse
(v
: Visitor)
587 if _n_kwprivate
!= null then
588 v
.visit
(_n_kwprivate
)
592 redef class AProtectedVisibility
593 redef meth n_kwprotected
=(n
: TKwprotected)
601 private init empty_init
do end
603 init init_aprotectedvisibility
(
604 n_kwprotected
: TKwprotected
607 _n_kwprotected
= n_kwprotected
608 if n_kwprotected
!= null then
609 n_kwprotected
.parent
= self
613 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
615 assert old_child
!= null
616 if _n_kwprotected
== old_child
then
617 if new_child
!= null then
618 new_child
.parent
= self
619 assert new_child
isa TKwprotected
620 _n_kwprotected
= new_child
622 _n_kwprotected
= null
628 redef meth visit_all
(v
: Visitor)
630 if _n_kwprotected
!= null then
631 v
.visit
(_n_kwprotected
)
635 redef meth visit_all_reverse
(v
: Visitor)
637 if _n_kwprotected
!= null then
638 v
.visit
(_n_kwprotected
)
642 redef class AIntrudeVisibility
643 redef meth n_kwintrude
=(n
: TKwintrude)
651 private init empty_init
do end
653 init init_aintrudevisibility
(
654 n_kwintrude
: TKwintrude
657 _n_kwintrude
= n_kwintrude
658 if n_kwintrude
!= null then
659 n_kwintrude
.parent
= self
663 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
665 assert old_child
!= null
666 if _n_kwintrude
== old_child
then
667 if new_child
!= null then
668 new_child
.parent
= self
669 assert new_child
isa TKwintrude
670 _n_kwintrude
= new_child
678 redef meth visit_all
(v
: Visitor)
680 if _n_kwintrude
!= null then
681 v
.visit
(_n_kwintrude
)
685 redef meth visit_all_reverse
(v
: Visitor)
687 if _n_kwintrude
!= null then
688 v
.visit
(_n_kwintrude
)
692 redef class AClassdef
693 redef meth n_doc
=(n
: PDoc)
700 redef meth n_kwredef
=(n
: TKwredef)
707 redef meth n_visibility
=(n
: PVisibility)
714 redef meth n_classkind
=(n
: PClasskind)
721 redef meth n_id
=(n
: TClassid)
729 private init empty_init
do end
731 init init_aclassdef
(
733 n_kwredef
: TKwredef ,
734 n_visibility
: PVisibility ,
735 n_classkind
: PClasskind ,
737 n_formaldefs
: Array[Object] , # Should be Array[PFormaldef]
738 n_superclasses
: Array[Object] , # Should be Array[PSuperclass]
739 n_propdefs
: Array[Object] # Should be Array[PPropdef]
743 if n_doc
!= null then
746 _n_kwredef
= n_kwredef
747 if n_kwredef
!= null then
748 n_kwredef
.parent
= self
750 _n_visibility
= n_visibility
751 if n_visibility
!= null then
752 n_visibility
.parent
= self
754 _n_classkind
= n_classkind
755 if n_classkind
!= null then
756 n_classkind
.parent
= self
762 _n_formaldefs
= new List[PFormaldef]
763 for n
in n_formaldefs
do
764 assert n
isa PFormaldef
768 _n_superclasses
= new List[PSuperclass]
769 for n
in n_superclasses
do
770 assert n
isa PSuperclass
771 _n_superclasses
.add
(n
)
774 _n_propdefs
= new List[PPropdef]
775 for n
in n_propdefs
do
776 assert n
isa PPropdef
782 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
784 assert old_child
!= null
785 if _n_doc
== old_child
then
786 if new_child
!= null then
787 new_child
.parent
= self
788 assert new_child
isa PDoc
795 if _n_kwredef
== old_child
then
796 if new_child
!= null then
797 new_child
.parent
= self
798 assert new_child
isa TKwredef
799 _n_kwredef
= new_child
805 if _n_visibility
== old_child
then
806 if new_child
!= null then
807 new_child
.parent
= self
808 assert new_child
isa PVisibility
809 _n_visibility
= new_child
815 if _n_classkind
== old_child
then
816 if new_child
!= null then
817 new_child
.parent
= self
818 assert new_child
isa PClasskind
819 _n_classkind
= new_child
825 if _n_id
== old_child
then
826 if new_child
!= null then
827 new_child
.parent
= self
828 assert new_child
isa TClassid
835 for i
in [0.._n_formaldefs
.length
[ do
836 if _n_formaldefs
[i
] == old_child
then
837 if new_child
!= null then
838 assert new_child
isa PFormaldef
839 _n_formaldefs
[i
] = new_child
840 new_child
.parent
= self
842 _n_formaldefs
.remove_at
(i
)
847 for i
in [0.._n_superclasses
.length
[ do
848 if _n_superclasses
[i
] == old_child
then
849 if new_child
!= null then
850 assert new_child
isa PSuperclass
851 _n_superclasses
[i
] = new_child
852 new_child
.parent
= self
854 _n_superclasses
.remove_at
(i
)
859 for i
in [0.._n_propdefs
.length
[ do
860 if _n_propdefs
[i
] == old_child
then
861 if new_child
!= null then
862 assert new_child
isa PPropdef
863 _n_propdefs
[i
] = new_child
864 new_child
.parent
= self
866 _n_propdefs
.remove_at
(i
)
873 redef meth visit_all
(v
: Visitor)
875 if _n_doc
!= null then
878 if _n_kwredef
!= null then
881 if _n_visibility
!= null then
882 v
.visit
(_n_visibility
)
884 if _n_classkind
!= null then
885 v
.visit
(_n_classkind
)
887 if _n_id
!= null then
890 for n
in _n_formaldefs
do
893 for n
in _n_superclasses
do
896 for n
in _n_propdefs
do
901 redef meth visit_all_reverse
(v
: Visitor)
903 if _n_doc
!= null then
906 if _n_kwredef
!= null then
909 if _n_visibility
!= null then
910 v
.visit
(_n_visibility
)
912 if _n_classkind
!= null then
913 v
.visit
(_n_classkind
)
915 if _n_id
!= null then
919 var i
= _n_formaldefs
.length
921 v
.visit
(_n_formaldefs
[i
])
926 var i
= _n_superclasses
.length
928 v
.visit
(_n_superclasses
[i
])
933 var i
= _n_propdefs
.length
935 v
.visit
(_n_propdefs
[i
])
941 redef class ATopClassdef
943 private init empty_init
do end
945 init init_atopclassdef
(
946 n_propdefs
: Array[Object] # Should be Array[PPropdef]
949 _n_propdefs
= new List[PPropdef]
950 for n
in n_propdefs
do
951 assert n
isa PPropdef
957 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
959 assert old_child
!= null
960 for i
in [0.._n_propdefs
.length
[ do
961 if _n_propdefs
[i
] == old_child
then
962 if new_child
!= null then
963 assert new_child
isa PPropdef
964 _n_propdefs
[i
] = new_child
965 new_child
.parent
= self
967 _n_propdefs
.remove_at
(i
)
974 redef meth visit_all
(v
: Visitor)
976 for n
in _n_propdefs
do
981 redef meth visit_all_reverse
(v
: Visitor)
984 var i
= _n_propdefs
.length
986 v
.visit
(_n_propdefs
[i
])
992 redef class AMainClassdef
994 private init empty_init
do end
996 init init_amainclassdef
(
997 n_propdefs
: Array[Object] # Should be Array[PPropdef]
1000 _n_propdefs
= new List[PPropdef]
1001 for n
in n_propdefs
do
1002 assert n
isa PPropdef
1008 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
1010 assert old_child
!= null
1011 for i
in [0.._n_propdefs
.length
[ do
1012 if _n_propdefs
[i
] == old_child
then
1013 if new_child
!= null then
1014 assert new_child
isa PPropdef
1015 _n_propdefs
[i
] = new_child
1016 new_child
.parent
= self
1018 _n_propdefs
.remove_at
(i
)
1025 redef meth visit_all
(v
: Visitor)
1027 for n
in _n_propdefs
do
1032 redef meth visit_all_reverse
(v
: Visitor)
1035 var i
= _n_propdefs
.length
1037 v
.visit
(_n_propdefs
[i
])
1043 redef class AConcreteClasskind
1044 redef meth n_kwclass
=(n
: TKwclass)
1052 private init empty_init
do end
1054 init init_aconcreteclasskind
(
1058 _n_kwclass
= n_kwclass
1059 if n_kwclass
!= null then
1060 n_kwclass
.parent
= self
1064 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
1066 assert old_child
!= null
1067 if _n_kwclass
== old_child
then
1068 if new_child
!= null then
1069 new_child
.parent
= self
1070 assert new_child
isa TKwclass
1071 _n_kwclass
= new_child
1079 redef meth visit_all
(v
: Visitor)
1081 if _n_kwclass
!= null then
1086 redef meth visit_all_reverse
(v
: Visitor)
1088 if _n_kwclass
!= null then
1093 redef class AAbstractClasskind
1094 redef meth n_kwabstract
=(n
: TKwabstract)
1101 redef meth n_kwclass
=(n
: TKwclass)
1109 private init empty_init
do end
1111 init init_aabstractclasskind
(
1112 n_kwabstract
: TKwabstract ,
1116 _n_kwabstract
= n_kwabstract
1117 if n_kwabstract
!= null then
1118 n_kwabstract
.parent
= self
1120 _n_kwclass
= n_kwclass
1121 if n_kwclass
!= null then
1122 n_kwclass
.parent
= self
1126 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
1128 assert old_child
!= null
1129 if _n_kwabstract
== old_child
then
1130 if new_child
!= null then
1131 new_child
.parent
= self
1132 assert new_child
isa TKwabstract
1133 _n_kwabstract
= new_child
1135 _n_kwabstract
= null
1139 if _n_kwclass
== old_child
then
1140 if new_child
!= null then
1141 new_child
.parent
= self
1142 assert new_child
isa TKwclass
1143 _n_kwclass
= new_child
1151 redef meth visit_all
(v
: Visitor)
1153 if _n_kwabstract
!= null then
1154 v
.visit
(_n_kwabstract
)
1156 if _n_kwclass
!= null then
1161 redef meth visit_all_reverse
(v
: Visitor)
1163 if _n_kwabstract
!= null then
1164 v
.visit
(_n_kwabstract
)
1166 if _n_kwclass
!= null then
1171 redef class AInterfaceClasskind
1172 redef meth n_kwinterface
=(n
: TKwinterface)
1180 private init empty_init
do end
1182 init init_ainterfaceclasskind
(
1183 n_kwinterface
: TKwinterface
1186 _n_kwinterface
= n_kwinterface
1187 if n_kwinterface
!= null then
1188 n_kwinterface
.parent
= self
1192 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
1194 assert old_child
!= null
1195 if _n_kwinterface
== old_child
then
1196 if new_child
!= null then
1197 new_child
.parent
= self
1198 assert new_child
isa TKwinterface
1199 _n_kwinterface
= new_child
1201 _n_kwinterface
= null
1207 redef meth visit_all
(v
: Visitor)
1209 if _n_kwinterface
!= null then
1210 v
.visit
(_n_kwinterface
)
1214 redef meth visit_all_reverse
(v
: Visitor)
1216 if _n_kwinterface
!= null then
1217 v
.visit
(_n_kwinterface
)
1221 redef class AUniversalClasskind
1222 redef meth n_kwuniversal
=(n
: TKwuniversal)
1230 private init empty_init
do end
1232 init init_auniversalclasskind
(
1233 n_kwuniversal
: TKwuniversal
1236 _n_kwuniversal
= n_kwuniversal
1237 if n_kwuniversal
!= null then
1238 n_kwuniversal
.parent
= self
1242 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
1244 assert old_child
!= null
1245 if _n_kwuniversal
== old_child
then
1246 if new_child
!= null then
1247 new_child
.parent
= self
1248 assert new_child
isa TKwuniversal
1249 _n_kwuniversal
= new_child
1251 _n_kwuniversal
= null
1257 redef meth visit_all
(v
: Visitor)
1259 if _n_kwuniversal
!= null then
1260 v
.visit
(_n_kwuniversal
)
1264 redef meth visit_all_reverse
(v
: Visitor)
1266 if _n_kwuniversal
!= null then
1267 v
.visit
(_n_kwuniversal
)
1271 redef class AFormaldef
1272 redef meth n_id
=(n
: TClassid)
1279 redef meth n_type
=(n
: PType)
1287 private init empty_init
do end
1289 init init_aformaldef
(
1295 if n_id
!= null then
1299 if n_type
!= null then
1300 n_type
.parent
= self
1304 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
1306 assert old_child
!= null
1307 if _n_id
== old_child
then
1308 if new_child
!= null then
1309 new_child
.parent
= self
1310 assert new_child
isa TClassid
1317 if _n_type
== old_child
then
1318 if new_child
!= null then
1319 new_child
.parent
= self
1320 assert new_child
isa PType
1329 redef meth visit_all
(v
: Visitor)
1331 if _n_id
!= null then
1334 if _n_type
!= null then
1339 redef meth visit_all_reverse
(v
: Visitor)
1341 if _n_id
!= null then
1344 if _n_type
!= null then
1349 redef class ASuperclass
1350 redef meth n_kwspecial
=(n
: TKwspecial)
1357 redef meth n_type
=(n
: PType)
1365 private init empty_init
do end
1367 init init_asuperclass
(
1368 n_kwspecial
: TKwspecial ,
1372 _n_kwspecial
= n_kwspecial
1373 if n_kwspecial
!= null then
1374 n_kwspecial
.parent
= self
1377 if n_type
!= null then
1378 n_type
.parent
= self
1382 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
1384 assert old_child
!= null
1385 if _n_kwspecial
== old_child
then
1386 if new_child
!= null then
1387 new_child
.parent
= self
1388 assert new_child
isa TKwspecial
1389 _n_kwspecial
= new_child
1395 if _n_type
== old_child
then
1396 if new_child
!= null then
1397 new_child
.parent
= self
1398 assert new_child
isa PType
1407 redef meth visit_all
(v
: Visitor)
1409 if _n_kwspecial
!= null then
1410 v
.visit
(_n_kwspecial
)
1412 if _n_type
!= null then
1417 redef meth visit_all_reverse
(v
: Visitor)
1419 if _n_kwspecial
!= null then
1420 v
.visit
(_n_kwspecial
)
1422 if _n_type
!= null then
1427 redef class AAttrPropdef
1428 redef meth n_doc
=(n
: PDoc)
1435 redef meth n_readable
=(n
: PAble)
1442 redef meth n_writable
=(n
: PAble)
1449 redef meth n_kwredef
=(n
: TKwredef)
1456 redef meth n_visibility
=(n
: PVisibility)
1463 redef meth n_kwattr
=(n
: TKwattr)
1470 redef meth n_id
=(n
: TAttrid)
1477 redef meth n_type
=(n
: PType)
1484 redef meth n_expr
=(n
: PExpr)
1492 private init empty_init
do end
1494 init init_aattrpropdef
(
1498 n_kwredef
: TKwredef ,
1499 n_visibility
: PVisibility ,
1507 if n_doc
!= null then
1510 _n_readable
= n_readable
1511 if n_readable
!= null then
1512 n_readable
.parent
= self
1514 _n_writable
= n_writable
1515 if n_writable
!= null then
1516 n_writable
.parent
= self
1518 _n_kwredef
= n_kwredef
1519 if n_kwredef
!= null then
1520 n_kwredef
.parent
= self
1522 _n_visibility
= n_visibility
1523 if n_visibility
!= null then
1524 n_visibility
.parent
= self
1526 _n_kwattr
= n_kwattr
1527 if n_kwattr
!= null then
1528 n_kwattr
.parent
= self
1531 if n_id
!= null then
1535 if n_type
!= null then
1536 n_type
.parent
= self
1539 if n_expr
!= null then
1540 n_expr
.parent
= self
1544 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
1546 assert old_child
!= null
1547 if _n_doc
== old_child
then
1548 if new_child
!= null then
1549 new_child
.parent
= self
1550 assert new_child
isa PDoc
1557 if _n_readable
== old_child
then
1558 if new_child
!= null then
1559 new_child
.parent
= self
1560 assert new_child
isa PAble
1561 _n_readable
= new_child
1567 if _n_writable
== old_child
then
1568 if new_child
!= null then
1569 new_child
.parent
= self
1570 assert new_child
isa PAble
1571 _n_writable
= new_child
1577 if _n_kwredef
== old_child
then
1578 if new_child
!= null then
1579 new_child
.parent
= self
1580 assert new_child
isa TKwredef
1581 _n_kwredef
= new_child
1587 if _n_visibility
== old_child
then
1588 if new_child
!= null then
1589 new_child
.parent
= self
1590 assert new_child
isa PVisibility
1591 _n_visibility
= new_child
1593 _n_visibility
= null
1597 if _n_kwattr
== old_child
then
1598 if new_child
!= null then
1599 new_child
.parent
= self
1600 assert new_child
isa TKwattr
1601 _n_kwattr
= new_child
1607 if _n_id
== old_child
then
1608 if new_child
!= null then
1609 new_child
.parent
= self
1610 assert new_child
isa TAttrid
1617 if _n_type
== old_child
then
1618 if new_child
!= null then
1619 new_child
.parent
= self
1620 assert new_child
isa PType
1627 if _n_expr
== old_child
then
1628 if new_child
!= null then
1629 new_child
.parent
= self
1630 assert new_child
isa PExpr
1639 redef meth visit_all
(v
: Visitor)
1641 if _n_doc
!= null then
1644 if _n_readable
!= null then
1645 v
.visit
(_n_readable
)
1647 if _n_writable
!= null then
1648 v
.visit
(_n_writable
)
1650 if _n_kwredef
!= null then
1653 if _n_visibility
!= null then
1654 v
.visit
(_n_visibility
)
1656 if _n_kwattr
!= null then
1659 if _n_id
!= null then
1662 if _n_type
!= null then
1665 if _n_expr
!= null then
1670 redef meth visit_all_reverse
(v
: Visitor)
1672 if _n_doc
!= null then
1675 if _n_readable
!= null then
1676 v
.visit
(_n_readable
)
1678 if _n_writable
!= null then
1679 v
.visit
(_n_writable
)
1681 if _n_kwredef
!= null then
1684 if _n_visibility
!= null then
1685 v
.visit
(_n_visibility
)
1687 if _n_kwattr
!= null then
1690 if _n_id
!= null then
1693 if _n_type
!= null then
1696 if _n_expr
!= null then
1701 redef class AMethPropdef
1702 redef meth n_doc
=(n
: PDoc)
1709 redef meth n_kwredef
=(n
: TKwredef)
1716 redef meth n_visibility
=(n
: PVisibility)
1723 redef meth n_methid
=(n
: PMethid)
1730 redef meth n_signature
=(n
: PSignature)
1738 private init empty_init
do end
1740 init init_amethpropdef
(
1742 n_kwredef
: TKwredef ,
1743 n_visibility
: PVisibility ,
1745 n_signature
: PSignature
1749 if n_doc
!= null then
1752 _n_kwredef
= n_kwredef
1753 if n_kwredef
!= null then
1754 n_kwredef
.parent
= self
1756 _n_visibility
= n_visibility
1757 if n_visibility
!= null then
1758 n_visibility
.parent
= self
1760 _n_methid
= n_methid
1761 if n_methid
!= null then
1762 n_methid
.parent
= self
1764 _n_signature
= n_signature
1765 if n_signature
!= null then
1766 n_signature
.parent
= self
1770 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
1772 assert old_child
!= null
1773 if _n_doc
== old_child
then
1774 if new_child
!= null then
1775 new_child
.parent
= self
1776 assert new_child
isa PDoc
1783 if _n_kwredef
== old_child
then
1784 if new_child
!= null then
1785 new_child
.parent
= self
1786 assert new_child
isa TKwredef
1787 _n_kwredef
= new_child
1793 if _n_visibility
== old_child
then
1794 if new_child
!= null then
1795 new_child
.parent
= self
1796 assert new_child
isa PVisibility
1797 _n_visibility
= new_child
1799 _n_visibility
= null
1803 if _n_methid
== old_child
then
1804 if new_child
!= null then
1805 new_child
.parent
= self
1806 assert new_child
isa PMethid
1807 _n_methid
= new_child
1813 if _n_signature
== old_child
then
1814 if new_child
!= null then
1815 new_child
.parent
= self
1816 assert new_child
isa PSignature
1817 _n_signature
= new_child
1825 redef meth visit_all
(v
: Visitor)
1827 if _n_doc
!= null then
1830 if _n_kwredef
!= null then
1833 if _n_visibility
!= null then
1834 v
.visit
(_n_visibility
)
1836 if _n_methid
!= null then
1839 if _n_signature
!= null then
1840 v
.visit
(_n_signature
)
1844 redef meth visit_all_reverse
(v
: Visitor)
1846 if _n_doc
!= null then
1849 if _n_kwredef
!= null then
1852 if _n_visibility
!= null then
1853 v
.visit
(_n_visibility
)
1855 if _n_methid
!= null then
1858 if _n_signature
!= null then
1859 v
.visit
(_n_signature
)
1863 redef class ADeferredMethPropdef
1864 redef meth n_doc
=(n
: PDoc)
1871 redef meth n_kwredef
=(n
: TKwredef)
1878 redef meth n_visibility
=(n
: PVisibility)
1885 redef meth n_kwmeth
=(n
: TKwmeth)
1892 redef meth n_methid
=(n
: PMethid)
1899 redef meth n_signature
=(n
: PSignature)
1907 private init empty_init
do end
1909 init init_adeferredmethpropdef
(
1911 n_kwredef
: TKwredef ,
1912 n_visibility
: PVisibility ,
1915 n_signature
: PSignature
1919 if n_doc
!= null then
1922 _n_kwredef
= n_kwredef
1923 if n_kwredef
!= null then
1924 n_kwredef
.parent
= self
1926 _n_visibility
= n_visibility
1927 if n_visibility
!= null then
1928 n_visibility
.parent
= self
1930 _n_kwmeth
= n_kwmeth
1931 if n_kwmeth
!= null then
1932 n_kwmeth
.parent
= self
1934 _n_methid
= n_methid
1935 if n_methid
!= null then
1936 n_methid
.parent
= self
1938 _n_signature
= n_signature
1939 if n_signature
!= null then
1940 n_signature
.parent
= self
1944 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
1946 assert old_child
!= null
1947 if _n_doc
== old_child
then
1948 if new_child
!= null then
1949 new_child
.parent
= self
1950 assert new_child
isa PDoc
1957 if _n_kwredef
== old_child
then
1958 if new_child
!= null then
1959 new_child
.parent
= self
1960 assert new_child
isa TKwredef
1961 _n_kwredef
= new_child
1967 if _n_visibility
== old_child
then
1968 if new_child
!= null then
1969 new_child
.parent
= self
1970 assert new_child
isa PVisibility
1971 _n_visibility
= new_child
1973 _n_visibility
= null
1977 if _n_kwmeth
== old_child
then
1978 if new_child
!= null then
1979 new_child
.parent
= self
1980 assert new_child
isa TKwmeth
1981 _n_kwmeth
= new_child
1987 if _n_methid
== old_child
then
1988 if new_child
!= null then
1989 new_child
.parent
= self
1990 assert new_child
isa PMethid
1991 _n_methid
= new_child
1997 if _n_signature
== old_child
then
1998 if new_child
!= null then
1999 new_child
.parent
= self
2000 assert new_child
isa PSignature
2001 _n_signature
= new_child
2009 redef meth visit_all
(v
: Visitor)
2011 if _n_doc
!= null then
2014 if _n_kwredef
!= null then
2017 if _n_visibility
!= null then
2018 v
.visit
(_n_visibility
)
2020 if _n_kwmeth
!= null then
2023 if _n_methid
!= null then
2026 if _n_signature
!= null then
2027 v
.visit
(_n_signature
)
2031 redef meth visit_all_reverse
(v
: Visitor)
2033 if _n_doc
!= null then
2036 if _n_kwredef
!= null then
2039 if _n_visibility
!= null then
2040 v
.visit
(_n_visibility
)
2042 if _n_kwmeth
!= null then
2045 if _n_methid
!= null then
2048 if _n_signature
!= null then
2049 v
.visit
(_n_signature
)
2053 redef class AInternMethPropdef
2054 redef meth n_doc
=(n
: PDoc)
2061 redef meth n_kwredef
=(n
: TKwredef)
2068 redef meth n_visibility
=(n
: PVisibility)
2075 redef meth n_kwmeth
=(n
: TKwmeth)
2082 redef meth n_methid
=(n
: PMethid)
2089 redef meth n_signature
=(n
: PSignature)
2097 private init empty_init
do end
2099 init init_ainternmethpropdef
(
2101 n_kwredef
: TKwredef ,
2102 n_visibility
: PVisibility ,
2105 n_signature
: PSignature
2109 if n_doc
!= null then
2112 _n_kwredef
= n_kwredef
2113 if n_kwredef
!= null then
2114 n_kwredef
.parent
= self
2116 _n_visibility
= n_visibility
2117 if n_visibility
!= null then
2118 n_visibility
.parent
= self
2120 _n_kwmeth
= n_kwmeth
2121 if n_kwmeth
!= null then
2122 n_kwmeth
.parent
= self
2124 _n_methid
= n_methid
2125 if n_methid
!= null then
2126 n_methid
.parent
= self
2128 _n_signature
= n_signature
2129 if n_signature
!= null then
2130 n_signature
.parent
= self
2134 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
2136 assert old_child
!= null
2137 if _n_doc
== old_child
then
2138 if new_child
!= null then
2139 new_child
.parent
= self
2140 assert new_child
isa PDoc
2147 if _n_kwredef
== old_child
then
2148 if new_child
!= null then
2149 new_child
.parent
= self
2150 assert new_child
isa TKwredef
2151 _n_kwredef
= new_child
2157 if _n_visibility
== old_child
then
2158 if new_child
!= null then
2159 new_child
.parent
= self
2160 assert new_child
isa PVisibility
2161 _n_visibility
= new_child
2163 _n_visibility
= null
2167 if _n_kwmeth
== old_child
then
2168 if new_child
!= null then
2169 new_child
.parent
= self
2170 assert new_child
isa TKwmeth
2171 _n_kwmeth
= new_child
2177 if _n_methid
== old_child
then
2178 if new_child
!= null then
2179 new_child
.parent
= self
2180 assert new_child
isa PMethid
2181 _n_methid
= new_child
2187 if _n_signature
== old_child
then
2188 if new_child
!= null then
2189 new_child
.parent
= self
2190 assert new_child
isa PSignature
2191 _n_signature
= new_child
2199 redef meth visit_all
(v
: Visitor)
2201 if _n_doc
!= null then
2204 if _n_kwredef
!= null then
2207 if _n_visibility
!= null then
2208 v
.visit
(_n_visibility
)
2210 if _n_kwmeth
!= null then
2213 if _n_methid
!= null then
2216 if _n_signature
!= null then
2217 v
.visit
(_n_signature
)
2221 redef meth visit_all_reverse
(v
: Visitor)
2223 if _n_doc
!= null then
2226 if _n_kwredef
!= null then
2229 if _n_visibility
!= null then
2230 v
.visit
(_n_visibility
)
2232 if _n_kwmeth
!= null then
2235 if _n_methid
!= null then
2238 if _n_signature
!= null then
2239 v
.visit
(_n_signature
)
2243 redef class AExternMethPropdef
2244 redef meth n_doc
=(n
: PDoc)
2251 redef meth n_kwredef
=(n
: TKwredef)
2258 redef meth n_visibility
=(n
: PVisibility)
2265 redef meth n_kwmeth
=(n
: TKwmeth)
2272 redef meth n_methid
=(n
: PMethid)
2279 redef meth n_signature
=(n
: PSignature)
2286 redef meth n_extern
=(n
: TString)
2294 private init empty_init
do end
2296 init init_aexternmethpropdef
(
2298 n_kwredef
: TKwredef ,
2299 n_visibility
: PVisibility ,
2302 n_signature
: PSignature ,
2307 if n_doc
!= null then
2310 _n_kwredef
= n_kwredef
2311 if n_kwredef
!= null then
2312 n_kwredef
.parent
= self
2314 _n_visibility
= n_visibility
2315 if n_visibility
!= null then
2316 n_visibility
.parent
= self
2318 _n_kwmeth
= n_kwmeth
2319 if n_kwmeth
!= null then
2320 n_kwmeth
.parent
= self
2322 _n_methid
= n_methid
2323 if n_methid
!= null then
2324 n_methid
.parent
= self
2326 _n_signature
= n_signature
2327 if n_signature
!= null then
2328 n_signature
.parent
= self
2330 _n_extern
= n_extern
2331 if n_extern
!= null then
2332 n_extern
.parent
= self
2336 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
2338 assert old_child
!= null
2339 if _n_doc
== old_child
then
2340 if new_child
!= null then
2341 new_child
.parent
= self
2342 assert new_child
isa PDoc
2349 if _n_kwredef
== old_child
then
2350 if new_child
!= null then
2351 new_child
.parent
= self
2352 assert new_child
isa TKwredef
2353 _n_kwredef
= new_child
2359 if _n_visibility
== old_child
then
2360 if new_child
!= null then
2361 new_child
.parent
= self
2362 assert new_child
isa PVisibility
2363 _n_visibility
= new_child
2365 _n_visibility
= null
2369 if _n_kwmeth
== old_child
then
2370 if new_child
!= null then
2371 new_child
.parent
= self
2372 assert new_child
isa TKwmeth
2373 _n_kwmeth
= new_child
2379 if _n_methid
== old_child
then
2380 if new_child
!= null then
2381 new_child
.parent
= self
2382 assert new_child
isa PMethid
2383 _n_methid
= new_child
2389 if _n_signature
== old_child
then
2390 if new_child
!= null then
2391 new_child
.parent
= self
2392 assert new_child
isa PSignature
2393 _n_signature
= new_child
2399 if _n_extern
== old_child
then
2400 if new_child
!= null then
2401 new_child
.parent
= self
2402 assert new_child
isa TString
2403 _n_extern
= new_child
2411 redef meth visit_all
(v
: Visitor)
2413 if _n_doc
!= null then
2416 if _n_kwredef
!= null then
2419 if _n_visibility
!= null then
2420 v
.visit
(_n_visibility
)
2422 if _n_kwmeth
!= null then
2425 if _n_methid
!= null then
2428 if _n_signature
!= null then
2429 v
.visit
(_n_signature
)
2431 if _n_extern
!= null then
2436 redef meth visit_all_reverse
(v
: Visitor)
2438 if _n_doc
!= null then
2441 if _n_kwredef
!= null then
2444 if _n_visibility
!= null then
2445 v
.visit
(_n_visibility
)
2447 if _n_kwmeth
!= null then
2450 if _n_methid
!= null then
2453 if _n_signature
!= null then
2454 v
.visit
(_n_signature
)
2456 if _n_extern
!= null then
2461 redef class AConcreteMethPropdef
2462 redef meth n_doc
=(n
: PDoc)
2469 redef meth n_kwredef
=(n
: TKwredef)
2476 redef meth n_visibility
=(n
: PVisibility)
2483 redef meth n_kwmeth
=(n
: TKwmeth)
2490 redef meth n_methid
=(n
: PMethid)
2497 redef meth n_signature
=(n
: PSignature)
2504 redef meth n_block
=(n
: PExpr)
2512 private init empty_init
do end
2514 init init_aconcretemethpropdef
(
2516 n_kwredef
: TKwredef ,
2517 n_visibility
: PVisibility ,
2520 n_signature
: PSignature ,
2525 if n_doc
!= null then
2528 _n_kwredef
= n_kwredef
2529 if n_kwredef
!= null then
2530 n_kwredef
.parent
= self
2532 _n_visibility
= n_visibility
2533 if n_visibility
!= null then
2534 n_visibility
.parent
= self
2536 _n_kwmeth
= n_kwmeth
2537 if n_kwmeth
!= null then
2538 n_kwmeth
.parent
= self
2540 _n_methid
= n_methid
2541 if n_methid
!= null then
2542 n_methid
.parent
= self
2544 _n_signature
= n_signature
2545 if n_signature
!= null then
2546 n_signature
.parent
= self
2549 if n_block
!= null then
2550 n_block
.parent
= self
2554 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
2556 assert old_child
!= null
2557 if _n_doc
== old_child
then
2558 if new_child
!= null then
2559 new_child
.parent
= self
2560 assert new_child
isa PDoc
2567 if _n_kwredef
== old_child
then
2568 if new_child
!= null then
2569 new_child
.parent
= self
2570 assert new_child
isa TKwredef
2571 _n_kwredef
= new_child
2577 if _n_visibility
== old_child
then
2578 if new_child
!= null then
2579 new_child
.parent
= self
2580 assert new_child
isa PVisibility
2581 _n_visibility
= new_child
2583 _n_visibility
= null
2587 if _n_kwmeth
== old_child
then
2588 if new_child
!= null then
2589 new_child
.parent
= self
2590 assert new_child
isa TKwmeth
2591 _n_kwmeth
= new_child
2597 if _n_methid
== old_child
then
2598 if new_child
!= null then
2599 new_child
.parent
= self
2600 assert new_child
isa PMethid
2601 _n_methid
= new_child
2607 if _n_signature
== old_child
then
2608 if new_child
!= null then
2609 new_child
.parent
= self
2610 assert new_child
isa PSignature
2611 _n_signature
= new_child
2617 if _n_block
== old_child
then
2618 if new_child
!= null then
2619 new_child
.parent
= self
2620 assert new_child
isa PExpr
2621 _n_block
= new_child
2629 redef meth visit_all
(v
: Visitor)
2631 if _n_doc
!= null then
2634 if _n_kwredef
!= null then
2637 if _n_visibility
!= null then
2638 v
.visit
(_n_visibility
)
2640 if _n_kwmeth
!= null then
2643 if _n_methid
!= null then
2646 if _n_signature
!= null then
2647 v
.visit
(_n_signature
)
2649 if _n_block
!= null then
2654 redef meth visit_all_reverse
(v
: Visitor)
2656 if _n_doc
!= null then
2659 if _n_kwredef
!= null then
2662 if _n_visibility
!= null then
2663 v
.visit
(_n_visibility
)
2665 if _n_kwmeth
!= null then
2668 if _n_methid
!= null then
2671 if _n_signature
!= null then
2672 v
.visit
(_n_signature
)
2674 if _n_block
!= null then
2679 redef class AConcreteInitPropdef
2680 redef meth n_doc
=(n
: PDoc)
2687 redef meth n_kwredef
=(n
: TKwredef)
2694 redef meth n_visibility
=(n
: PVisibility)
2701 redef meth n_kwinit
=(n
: TKwinit)
2708 redef meth n_methid
=(n
: PMethid)
2715 redef meth n_signature
=(n
: PSignature)
2722 redef meth n_block
=(n
: PExpr)
2730 private init empty_init
do end
2732 init init_aconcreteinitpropdef
(
2734 n_kwredef
: TKwredef ,
2735 n_visibility
: PVisibility ,
2738 n_signature
: PSignature ,
2743 if n_doc
!= null then
2746 _n_kwredef
= n_kwredef
2747 if n_kwredef
!= null then
2748 n_kwredef
.parent
= self
2750 _n_visibility
= n_visibility
2751 if n_visibility
!= null then
2752 n_visibility
.parent
= self
2754 _n_kwinit
= n_kwinit
2755 if n_kwinit
!= null then
2756 n_kwinit
.parent
= self
2758 _n_methid
= n_methid
2759 if n_methid
!= null then
2760 n_methid
.parent
= self
2762 _n_signature
= n_signature
2763 if n_signature
!= null then
2764 n_signature
.parent
= self
2767 if n_block
!= null then
2768 n_block
.parent
= self
2772 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
2774 assert old_child
!= null
2775 if _n_doc
== old_child
then
2776 if new_child
!= null then
2777 new_child
.parent
= self
2778 assert new_child
isa PDoc
2785 if _n_kwredef
== old_child
then
2786 if new_child
!= null then
2787 new_child
.parent
= self
2788 assert new_child
isa TKwredef
2789 _n_kwredef
= new_child
2795 if _n_visibility
== old_child
then
2796 if new_child
!= null then
2797 new_child
.parent
= self
2798 assert new_child
isa PVisibility
2799 _n_visibility
= new_child
2801 _n_visibility
= null
2805 if _n_kwinit
== old_child
then
2806 if new_child
!= null then
2807 new_child
.parent
= self
2808 assert new_child
isa TKwinit
2809 _n_kwinit
= new_child
2815 if _n_methid
== old_child
then
2816 if new_child
!= null then
2817 new_child
.parent
= self
2818 assert new_child
isa PMethid
2819 _n_methid
= new_child
2825 if _n_signature
== old_child
then
2826 if new_child
!= null then
2827 new_child
.parent
= self
2828 assert new_child
isa PSignature
2829 _n_signature
= new_child
2835 if _n_block
== old_child
then
2836 if new_child
!= null then
2837 new_child
.parent
= self
2838 assert new_child
isa PExpr
2839 _n_block
= new_child
2847 redef meth visit_all
(v
: Visitor)
2849 if _n_doc
!= null then
2852 if _n_kwredef
!= null then
2855 if _n_visibility
!= null then
2856 v
.visit
(_n_visibility
)
2858 if _n_kwinit
!= null then
2861 if _n_methid
!= null then
2864 if _n_signature
!= null then
2865 v
.visit
(_n_signature
)
2867 if _n_block
!= null then
2872 redef meth visit_all_reverse
(v
: Visitor)
2874 if _n_doc
!= null then
2877 if _n_kwredef
!= null then
2880 if _n_visibility
!= null then
2881 v
.visit
(_n_visibility
)
2883 if _n_kwinit
!= null then
2886 if _n_methid
!= null then
2889 if _n_signature
!= null then
2890 v
.visit
(_n_signature
)
2892 if _n_block
!= null then
2897 redef class AMainMethPropdef
2898 redef meth n_kwredef
=(n
: TKwredef)
2905 redef meth n_block
=(n
: PExpr)
2913 private init empty_init
do end
2915 init init_amainmethpropdef
(
2916 n_kwredef
: TKwredef ,
2920 _n_kwredef
= n_kwredef
2921 if n_kwredef
!= null then
2922 n_kwredef
.parent
= self
2925 if n_block
!= null then
2926 n_block
.parent
= self
2930 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
2932 assert old_child
!= null
2933 if _n_kwredef
== old_child
then
2934 if new_child
!= null then
2935 new_child
.parent
= self
2936 assert new_child
isa TKwredef
2937 _n_kwredef
= new_child
2943 if _n_block
== old_child
then
2944 if new_child
!= null then
2945 new_child
.parent
= self
2946 assert new_child
isa PExpr
2947 _n_block
= new_child
2955 redef meth visit_all
(v
: Visitor)
2957 if _n_kwredef
!= null then
2960 if _n_block
!= null then
2965 redef meth visit_all_reverse
(v
: Visitor)
2967 if _n_kwredef
!= null then
2970 if _n_block
!= null then
2975 redef class ATypePropdef
2976 redef meth n_doc
=(n
: PDoc)
2983 redef meth n_kwredef
=(n
: TKwredef)
2990 redef meth n_visibility
=(n
: PVisibility)
2997 redef meth n_kwtype
=(n
: TKwtype)
3004 redef meth n_id
=(n
: TClassid)
3011 redef meth n_type
=(n
: PType)
3019 private init empty_init
do end
3021 init init_atypepropdef
(
3023 n_kwredef
: TKwredef ,
3024 n_visibility
: PVisibility ,
3031 if n_doc
!= null then
3034 _n_kwredef
= n_kwredef
3035 if n_kwredef
!= null then
3036 n_kwredef
.parent
= self
3038 _n_visibility
= n_visibility
3039 if n_visibility
!= null then
3040 n_visibility
.parent
= self
3042 _n_kwtype
= n_kwtype
3043 if n_kwtype
!= null then
3044 n_kwtype
.parent
= self
3047 if n_id
!= null then
3051 if n_type
!= null then
3052 n_type
.parent
= self
3056 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3058 assert old_child
!= null
3059 if _n_doc
== old_child
then
3060 if new_child
!= null then
3061 new_child
.parent
= self
3062 assert new_child
isa PDoc
3069 if _n_kwredef
== old_child
then
3070 if new_child
!= null then
3071 new_child
.parent
= self
3072 assert new_child
isa TKwredef
3073 _n_kwredef
= new_child
3079 if _n_visibility
== old_child
then
3080 if new_child
!= null then
3081 new_child
.parent
= self
3082 assert new_child
isa PVisibility
3083 _n_visibility
= new_child
3085 _n_visibility
= null
3089 if _n_kwtype
== old_child
then
3090 if new_child
!= null then
3091 new_child
.parent
= self
3092 assert new_child
isa TKwtype
3093 _n_kwtype
= new_child
3099 if _n_id
== old_child
then
3100 if new_child
!= null then
3101 new_child
.parent
= self
3102 assert new_child
isa TClassid
3109 if _n_type
== old_child
then
3110 if new_child
!= null then
3111 new_child
.parent
= self
3112 assert new_child
isa PType
3121 redef meth visit_all
(v
: Visitor)
3123 if _n_doc
!= null then
3126 if _n_kwredef
!= null then
3129 if _n_visibility
!= null then
3130 v
.visit
(_n_visibility
)
3132 if _n_kwtype
!= null then
3135 if _n_id
!= null then
3138 if _n_type
!= null then
3143 redef meth visit_all_reverse
(v
: Visitor)
3145 if _n_doc
!= null then
3148 if _n_kwredef
!= null then
3151 if _n_visibility
!= null then
3152 v
.visit
(_n_visibility
)
3154 if _n_kwtype
!= null then
3157 if _n_id
!= null then
3160 if _n_type
!= null then
3165 redef class AReadAble
3166 redef meth n_kwredef
=(n
: TKwredef)
3173 redef meth n_kwreadable
=(n
: TKwreadable)
3181 private init empty_init
do end
3183 init init_areadable
(
3184 n_kwredef
: TKwredef ,
3185 n_kwreadable
: TKwreadable
3188 _n_kwredef
= n_kwredef
3189 if n_kwredef
!= null then
3190 n_kwredef
.parent
= self
3192 _n_kwreadable
= n_kwreadable
3193 if n_kwreadable
!= null then
3194 n_kwreadable
.parent
= self
3198 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3200 assert old_child
!= null
3201 if _n_kwredef
== old_child
then
3202 if new_child
!= null then
3203 new_child
.parent
= self
3204 assert new_child
isa TKwredef
3205 _n_kwredef
= new_child
3211 if _n_kwreadable
== old_child
then
3212 if new_child
!= null then
3213 new_child
.parent
= self
3214 assert new_child
isa TKwreadable
3215 _n_kwreadable
= new_child
3217 _n_kwreadable
= null
3223 redef meth visit_all
(v
: Visitor)
3225 if _n_kwredef
!= null then
3228 if _n_kwreadable
!= null then
3229 v
.visit
(_n_kwreadable
)
3233 redef meth visit_all_reverse
(v
: Visitor)
3235 if _n_kwredef
!= null then
3238 if _n_kwreadable
!= null then
3239 v
.visit
(_n_kwreadable
)
3243 redef class AWriteAble
3244 redef meth n_kwredef
=(n
: TKwredef)
3251 redef meth n_kwwritable
=(n
: TKwwritable)
3259 private init empty_init
do end
3261 init init_awriteable
(
3262 n_kwredef
: TKwredef ,
3263 n_kwwritable
: TKwwritable
3266 _n_kwredef
= n_kwredef
3267 if n_kwredef
!= null then
3268 n_kwredef
.parent
= self
3270 _n_kwwritable
= n_kwwritable
3271 if n_kwwritable
!= null then
3272 n_kwwritable
.parent
= self
3276 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3278 assert old_child
!= null
3279 if _n_kwredef
== old_child
then
3280 if new_child
!= null then
3281 new_child
.parent
= self
3282 assert new_child
isa TKwredef
3283 _n_kwredef
= new_child
3289 if _n_kwwritable
== old_child
then
3290 if new_child
!= null then
3291 new_child
.parent
= self
3292 assert new_child
isa TKwwritable
3293 _n_kwwritable
= new_child
3295 _n_kwwritable
= null
3301 redef meth visit_all
(v
: Visitor)
3303 if _n_kwredef
!= null then
3306 if _n_kwwritable
!= null then
3307 v
.visit
(_n_kwwritable
)
3311 redef meth visit_all_reverse
(v
: Visitor)
3313 if _n_kwredef
!= null then
3316 if _n_kwwritable
!= null then
3317 v
.visit
(_n_kwwritable
)
3321 redef class AIdMethid
3322 redef meth n_id
=(n
: TId)
3330 private init empty_init
do end
3332 init init_aidmethid
(
3337 if n_id
!= null then
3342 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3344 assert old_child
!= null
3345 if _n_id
== old_child
then
3346 if new_child
!= null then
3347 new_child
.parent
= self
3348 assert new_child
isa TId
3357 redef meth visit_all
(v
: Visitor)
3359 if _n_id
!= null then
3364 redef meth visit_all_reverse
(v
: Visitor)
3366 if _n_id
!= null then
3371 redef class APlusMethid
3372 redef meth n_plus
=(n
: TPlus)
3380 private init empty_init
do end
3382 init init_aplusmethid
(
3387 if n_plus
!= null then
3388 n_plus
.parent
= self
3392 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3394 assert old_child
!= null
3395 if _n_plus
== old_child
then
3396 if new_child
!= null then
3397 new_child
.parent
= self
3398 assert new_child
isa TPlus
3407 redef meth visit_all
(v
: Visitor)
3409 if _n_plus
!= null then
3414 redef meth visit_all_reverse
(v
: Visitor)
3416 if _n_plus
!= null then
3421 redef class AMinusMethid
3422 redef meth n_minus
=(n
: TMinus)
3430 private init empty_init
do end
3432 init init_aminusmethid
(
3437 if n_minus
!= null then
3438 n_minus
.parent
= self
3442 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3444 assert old_child
!= null
3445 if _n_minus
== old_child
then
3446 if new_child
!= null then
3447 new_child
.parent
= self
3448 assert new_child
isa TMinus
3449 _n_minus
= new_child
3457 redef meth visit_all
(v
: Visitor)
3459 if _n_minus
!= null then
3464 redef meth visit_all_reverse
(v
: Visitor)
3466 if _n_minus
!= null then
3471 redef class AStarMethid
3472 redef meth n_star
=(n
: TStar)
3480 private init empty_init
do end
3482 init init_astarmethid
(
3487 if n_star
!= null then
3488 n_star
.parent
= self
3492 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3494 assert old_child
!= null
3495 if _n_star
== old_child
then
3496 if new_child
!= null then
3497 new_child
.parent
= self
3498 assert new_child
isa TStar
3507 redef meth visit_all
(v
: Visitor)
3509 if _n_star
!= null then
3514 redef meth visit_all_reverse
(v
: Visitor)
3516 if _n_star
!= null then
3521 redef class ASlashMethid
3522 redef meth n_slash
=(n
: TSlash)
3530 private init empty_init
do end
3532 init init_aslashmethid
(
3537 if n_slash
!= null then
3538 n_slash
.parent
= self
3542 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3544 assert old_child
!= null
3545 if _n_slash
== old_child
then
3546 if new_child
!= null then
3547 new_child
.parent
= self
3548 assert new_child
isa TSlash
3549 _n_slash
= new_child
3557 redef meth visit_all
(v
: Visitor)
3559 if _n_slash
!= null then
3564 redef meth visit_all_reverse
(v
: Visitor)
3566 if _n_slash
!= null then
3571 redef class APercentMethid
3572 redef meth n_percent
=(n
: TPercent)
3580 private init empty_init
do end
3582 init init_apercentmethid
(
3586 _n_percent
= n_percent
3587 if n_percent
!= null then
3588 n_percent
.parent
= self
3592 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3594 assert old_child
!= null
3595 if _n_percent
== old_child
then
3596 if new_child
!= null then
3597 new_child
.parent
= self
3598 assert new_child
isa TPercent
3599 _n_percent
= new_child
3607 redef meth visit_all
(v
: Visitor)
3609 if _n_percent
!= null then
3614 redef meth visit_all_reverse
(v
: Visitor)
3616 if _n_percent
!= null then
3621 redef class AEqMethid
3622 redef meth n_eq
=(n
: TEq)
3630 private init empty_init
do end
3632 init init_aeqmethid
(
3637 if n_eq
!= null then
3642 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3644 assert old_child
!= null
3645 if _n_eq
== old_child
then
3646 if new_child
!= null then
3647 new_child
.parent
= self
3648 assert new_child
isa TEq
3657 redef meth visit_all
(v
: Visitor)
3659 if _n_eq
!= null then
3664 redef meth visit_all_reverse
(v
: Visitor)
3666 if _n_eq
!= null then
3671 redef class ANeMethid
3672 redef meth n_ne
=(n
: TNe)
3680 private init empty_init
do end
3682 init init_anemethid
(
3687 if n_ne
!= null then
3692 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3694 assert old_child
!= null
3695 if _n_ne
== old_child
then
3696 if new_child
!= null then
3697 new_child
.parent
= self
3698 assert new_child
isa TNe
3707 redef meth visit_all
(v
: Visitor)
3709 if _n_ne
!= null then
3714 redef meth visit_all_reverse
(v
: Visitor)
3716 if _n_ne
!= null then
3721 redef class ALeMethid
3722 redef meth n_le
=(n
: TLe)
3730 private init empty_init
do end
3732 init init_alemethid
(
3737 if n_le
!= null then
3742 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3744 assert old_child
!= null
3745 if _n_le
== old_child
then
3746 if new_child
!= null then
3747 new_child
.parent
= self
3748 assert new_child
isa TLe
3757 redef meth visit_all
(v
: Visitor)
3759 if _n_le
!= null then
3764 redef meth visit_all_reverse
(v
: Visitor)
3766 if _n_le
!= null then
3771 redef class AGeMethid
3772 redef meth n_ge
=(n
: TGe)
3780 private init empty_init
do end
3782 init init_agemethid
(
3787 if n_ge
!= null then
3792 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3794 assert old_child
!= null
3795 if _n_ge
== old_child
then
3796 if new_child
!= null then
3797 new_child
.parent
= self
3798 assert new_child
isa TGe
3807 redef meth visit_all
(v
: Visitor)
3809 if _n_ge
!= null then
3814 redef meth visit_all_reverse
(v
: Visitor)
3816 if _n_ge
!= null then
3821 redef class ALtMethid
3822 redef meth n_lt
=(n
: TLt)
3830 private init empty_init
do end
3832 init init_altmethid
(
3837 if n_lt
!= null then
3842 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3844 assert old_child
!= null
3845 if _n_lt
== old_child
then
3846 if new_child
!= null then
3847 new_child
.parent
= self
3848 assert new_child
isa TLt
3857 redef meth visit_all
(v
: Visitor)
3859 if _n_lt
!= null then
3864 redef meth visit_all_reverse
(v
: Visitor)
3866 if _n_lt
!= null then
3871 redef class AGtMethid
3872 redef meth n_gt
=(n
: TGt)
3880 private init empty_init
do end
3882 init init_agtmethid
(
3887 if n_gt
!= null then
3892 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3894 assert old_child
!= null
3895 if _n_gt
== old_child
then
3896 if new_child
!= null then
3897 new_child
.parent
= self
3898 assert new_child
isa TGt
3907 redef meth visit_all
(v
: Visitor)
3909 if _n_gt
!= null then
3914 redef meth visit_all_reverse
(v
: Visitor)
3916 if _n_gt
!= null then
3921 redef class ABraMethid
3922 redef meth n_obra
=(n
: TObra)
3929 redef meth n_cbra
=(n
: TCbra)
3937 private init empty_init
do end
3939 init init_abramethid
(
3945 if n_obra
!= null then
3946 n_obra
.parent
= self
3949 if n_cbra
!= null then
3950 n_cbra
.parent
= self
3954 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
3956 assert old_child
!= null
3957 if _n_obra
== old_child
then
3958 if new_child
!= null then
3959 new_child
.parent
= self
3960 assert new_child
isa TObra
3967 if _n_cbra
== old_child
then
3968 if new_child
!= null then
3969 new_child
.parent
= self
3970 assert new_child
isa TCbra
3979 redef meth visit_all
(v
: Visitor)
3981 if _n_obra
!= null then
3984 if _n_cbra
!= null then
3989 redef meth visit_all_reverse
(v
: Visitor)
3991 if _n_obra
!= null then
3994 if _n_cbra
!= null then
3999 redef class AStarshipMethid
4000 redef meth n_starship
=(n
: TStarship)
4008 private init empty_init
do end
4010 init init_astarshipmethid
(
4011 n_starship
: TStarship
4014 _n_starship
= n_starship
4015 if n_starship
!= null then
4016 n_starship
.parent
= self
4020 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
4022 assert old_child
!= null
4023 if _n_starship
== old_child
then
4024 if new_child
!= null then
4025 new_child
.parent
= self
4026 assert new_child
isa TStarship
4027 _n_starship
= new_child
4035 redef meth visit_all
(v
: Visitor)
4037 if _n_starship
!= null then
4038 v
.visit
(_n_starship
)
4042 redef meth visit_all_reverse
(v
: Visitor)
4044 if _n_starship
!= null then
4045 v
.visit
(_n_starship
)
4049 redef class AAssignMethid
4050 redef meth n_id
=(n
: TId)
4057 redef meth n_assign
=(n
: TAssign)
4065 private init empty_init
do end
4067 init init_aassignmethid
(
4073 if n_id
!= null then
4076 _n_assign
= n_assign
4077 if n_assign
!= null then
4078 n_assign
.parent
= self
4082 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
4084 assert old_child
!= null
4085 if _n_id
== old_child
then
4086 if new_child
!= null then
4087 new_child
.parent
= self
4088 assert new_child
isa TId
4095 if _n_assign
== old_child
then
4096 if new_child
!= null then
4097 new_child
.parent
= self
4098 assert new_child
isa TAssign
4099 _n_assign
= new_child
4107 redef meth visit_all
(v
: Visitor)
4109 if _n_id
!= null then
4112 if _n_assign
!= null then
4117 redef meth visit_all_reverse
(v
: Visitor)
4119 if _n_id
!= null then
4122 if _n_assign
!= null then
4127 redef class ABraassignMethid
4128 redef meth n_obra
=(n
: TObra)
4135 redef meth n_cbra
=(n
: TCbra)
4142 redef meth n_assign
=(n
: TAssign)
4150 private init empty_init
do end
4152 init init_abraassignmethid
(
4159 if n_obra
!= null then
4160 n_obra
.parent
= self
4163 if n_cbra
!= null then
4164 n_cbra
.parent
= self
4166 _n_assign
= n_assign
4167 if n_assign
!= null then
4168 n_assign
.parent
= self
4172 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
4174 assert old_child
!= null
4175 if _n_obra
== old_child
then
4176 if new_child
!= null then
4177 new_child
.parent
= self
4178 assert new_child
isa TObra
4185 if _n_cbra
== old_child
then
4186 if new_child
!= null then
4187 new_child
.parent
= self
4188 assert new_child
isa TCbra
4195 if _n_assign
== old_child
then
4196 if new_child
!= null then
4197 new_child
.parent
= self
4198 assert new_child
isa TAssign
4199 _n_assign
= new_child
4207 redef meth visit_all
(v
: Visitor)
4209 if _n_obra
!= null then
4212 if _n_cbra
!= null then
4215 if _n_assign
!= null then
4220 redef meth visit_all_reverse
(v
: Visitor)
4222 if _n_obra
!= null then
4225 if _n_cbra
!= null then
4228 if _n_assign
!= null then
4233 redef class ASignature
4234 redef meth n_type
=(n
: PType)
4242 private init empty_init
do end
4244 init init_asignature
(
4245 n_params
: Array[Object] , # Should be Array[PParam]
4249 _n_params
= new List[PParam]
4250 for n
in n_params
do
4256 if n_type
!= null then
4257 n_type
.parent
= self
4261 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
4263 assert old_child
!= null
4264 for i
in [0.._n_params
.length
[ do
4265 if _n_params
[i
] == old_child
then
4266 if new_child
!= null then
4267 assert new_child
isa PParam
4268 _n_params
[i
] = new_child
4269 new_child
.parent
= self
4271 _n_params
.remove_at
(i
)
4276 if _n_type
== old_child
then
4277 if new_child
!= null then
4278 new_child
.parent
= self
4279 assert new_child
isa PType
4288 redef meth visit_all
(v
: Visitor)
4290 for n
in _n_params
do
4293 if _n_type
!= null then
4298 redef meth visit_all_reverse
(v
: Visitor)
4301 var i
= _n_params
.length
4303 v
.visit
(_n_params
[i
])
4307 if _n_type
!= null then
4313 redef meth n_id
=(n
: TId)
4320 redef meth n_type
=(n
: PType)
4327 redef meth n_dotdotdot
=(n
: TDotdotdot)
4335 private init empty_init
do end
4340 n_dotdotdot
: TDotdotdot
4344 if n_id
!= null then
4348 if n_type
!= null then
4349 n_type
.parent
= self
4351 _n_dotdotdot
= n_dotdotdot
4352 if n_dotdotdot
!= null then
4353 n_dotdotdot
.parent
= self
4357 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
4359 assert old_child
!= null
4360 if _n_id
== old_child
then
4361 if new_child
!= null then
4362 new_child
.parent
= self
4363 assert new_child
isa TId
4370 if _n_type
== old_child
then
4371 if new_child
!= null then
4372 new_child
.parent
= self
4373 assert new_child
isa PType
4380 if _n_dotdotdot
== old_child
then
4381 if new_child
!= null then
4382 new_child
.parent
= self
4383 assert new_child
isa TDotdotdot
4384 _n_dotdotdot
= new_child
4392 redef meth visit_all
(v
: Visitor)
4394 if _n_id
!= null then
4397 if _n_type
!= null then
4400 if _n_dotdotdot
!= null then
4401 v
.visit
(_n_dotdotdot
)
4405 redef meth visit_all_reverse
(v
: Visitor)
4407 if _n_id
!= null then
4410 if _n_type
!= null then
4413 if _n_dotdotdot
!= null then
4414 v
.visit
(_n_dotdotdot
)
4419 redef meth n_id
=(n
: TClassid)
4427 private init empty_init
do end
4431 n_types
: Array[Object] # Should be Array[PType]
4435 if n_id
!= null then
4438 _n_types
= new List[PType]
4446 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
4448 assert old_child
!= null
4449 if _n_id
== old_child
then
4450 if new_child
!= null then
4451 new_child
.parent
= self
4452 assert new_child
isa TClassid
4459 for i
in [0.._n_types
.length
[ do
4460 if _n_types
[i
] == old_child
then
4461 if new_child
!= null then
4462 assert new_child
isa PType
4463 _n_types
[i
] = new_child
4464 new_child
.parent
= self
4466 _n_types
.remove_at
(i
)
4473 redef meth visit_all
(v
: Visitor)
4475 if _n_id
!= null then
4478 for n
in _n_types
do
4483 redef meth visit_all_reverse
(v
: Visitor)
4485 if _n_id
!= null then
4489 var i
= _n_types
.length
4491 v
.visit
(_n_types
[i
])
4497 redef class ABlockExpr
4499 private init empty_init
do end
4501 init init_ablockexpr
(
4502 n_expr
: Array[Object] # Should be Array[PExpr]
4505 _n_expr
= new List[PExpr]
4513 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
4515 assert old_child
!= null
4516 for i
in [0.._n_expr
.length
[ do
4517 if _n_expr
[i
] == old_child
then
4518 if new_child
!= null then
4519 assert new_child
isa PExpr
4520 _n_expr
[i
] = new_child
4521 new_child
.parent
= self
4523 _n_expr
.remove_at
(i
)
4530 redef meth visit_all
(v
: Visitor)
4537 redef meth visit_all_reverse
(v
: Visitor)
4540 var i
= _n_expr
.length
4548 redef class AVardeclExpr
4549 redef meth n_kwvar
=(n
: TKwvar)
4556 redef meth n_id
=(n
: TId)
4563 redef meth n_type
=(n
: PType)
4570 redef meth n_assign
=(n
: TAssign)
4577 redef meth n_expr
=(n
: PExpr)
4585 private init empty_init
do end
4587 init init_avardeclexpr
(
4596 if n_kwvar
!= null then
4597 n_kwvar
.parent
= self
4600 if n_id
!= null then
4604 if n_type
!= null then
4605 n_type
.parent
= self
4607 _n_assign
= n_assign
4608 if n_assign
!= null then
4609 n_assign
.parent
= self
4612 if n_expr
!= null then
4613 n_expr
.parent
= self
4617 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
4619 assert old_child
!= null
4620 if _n_kwvar
== old_child
then
4621 if new_child
!= null then
4622 new_child
.parent
= self
4623 assert new_child
isa TKwvar
4624 _n_kwvar
= new_child
4630 if _n_id
== old_child
then
4631 if new_child
!= null then
4632 new_child
.parent
= self
4633 assert new_child
isa TId
4640 if _n_type
== old_child
then
4641 if new_child
!= null then
4642 new_child
.parent
= self
4643 assert new_child
isa PType
4650 if _n_assign
== old_child
then
4651 if new_child
!= null then
4652 new_child
.parent
= self
4653 assert new_child
isa TAssign
4654 _n_assign
= new_child
4660 if _n_expr
== old_child
then
4661 if new_child
!= null then
4662 new_child
.parent
= self
4663 assert new_child
isa PExpr
4672 redef meth visit_all
(v
: Visitor)
4674 if _n_kwvar
!= null then
4677 if _n_id
!= null then
4680 if _n_type
!= null then
4683 if _n_assign
!= null then
4686 if _n_expr
!= null then
4691 redef meth visit_all_reverse
(v
: Visitor)
4693 if _n_kwvar
!= null then
4696 if _n_id
!= null then
4699 if _n_type
!= null then
4702 if _n_assign
!= null then
4705 if _n_expr
!= null then
4710 redef class AReturnExpr
4711 redef meth n_kwreturn
=(n
: TKwreturn)
4718 redef meth n_expr
=(n
: PExpr)
4726 private init empty_init
do end
4728 init init_areturnexpr
(
4729 n_kwreturn
: TKwreturn ,
4733 _n_kwreturn
= n_kwreturn
4734 if n_kwreturn
!= null then
4735 n_kwreturn
.parent
= self
4738 if n_expr
!= null then
4739 n_expr
.parent
= self
4743 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
4745 assert old_child
!= null
4746 if _n_kwreturn
== old_child
then
4747 if new_child
!= null then
4748 new_child
.parent
= self
4749 assert new_child
isa TKwreturn
4750 _n_kwreturn
= new_child
4756 if _n_expr
== old_child
then
4757 if new_child
!= null then
4758 new_child
.parent
= self
4759 assert new_child
isa PExpr
4768 redef meth visit_all
(v
: Visitor)
4770 if _n_kwreturn
!= null then
4771 v
.visit
(_n_kwreturn
)
4773 if _n_expr
!= null then
4778 redef meth visit_all_reverse
(v
: Visitor)
4780 if _n_kwreturn
!= null then
4781 v
.visit
(_n_kwreturn
)
4783 if _n_expr
!= null then
4788 redef class ABreakExpr
4789 redef meth n_kwbreak
=(n
: TKwbreak)
4797 private init empty_init
do end
4799 init init_abreakexpr
(
4803 _n_kwbreak
= n_kwbreak
4804 if n_kwbreak
!= null then
4805 n_kwbreak
.parent
= self
4809 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
4811 assert old_child
!= null
4812 if _n_kwbreak
== old_child
then
4813 if new_child
!= null then
4814 new_child
.parent
= self
4815 assert new_child
isa TKwbreak
4816 _n_kwbreak
= new_child
4824 redef meth visit_all
(v
: Visitor)
4826 if _n_kwbreak
!= null then
4831 redef meth visit_all_reverse
(v
: Visitor)
4833 if _n_kwbreak
!= null then
4838 redef class AAbortExpr
4839 redef meth n_kwabort
=(n
: TKwabort)
4847 private init empty_init
do end
4849 init init_aabortexpr
(
4853 _n_kwabort
= n_kwabort
4854 if n_kwabort
!= null then
4855 n_kwabort
.parent
= self
4859 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
4861 assert old_child
!= null
4862 if _n_kwabort
== old_child
then
4863 if new_child
!= null then
4864 new_child
.parent
= self
4865 assert new_child
isa TKwabort
4866 _n_kwabort
= new_child
4874 redef meth visit_all
(v
: Visitor)
4876 if _n_kwabort
!= null then
4881 redef meth visit_all_reverse
(v
: Visitor)
4883 if _n_kwabort
!= null then
4888 redef class AContinueExpr
4889 redef meth n_kwcontinue
=(n
: TKwcontinue)
4897 private init empty_init
do end
4899 init init_acontinueexpr
(
4900 n_kwcontinue
: TKwcontinue
4903 _n_kwcontinue
= n_kwcontinue
4904 if n_kwcontinue
!= null then
4905 n_kwcontinue
.parent
= self
4909 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
4911 assert old_child
!= null
4912 if _n_kwcontinue
== old_child
then
4913 if new_child
!= null then
4914 new_child
.parent
= self
4915 assert new_child
isa TKwcontinue
4916 _n_kwcontinue
= new_child
4918 _n_kwcontinue
= null
4924 redef meth visit_all
(v
: Visitor)
4926 if _n_kwcontinue
!= null then
4927 v
.visit
(_n_kwcontinue
)
4931 redef meth visit_all_reverse
(v
: Visitor)
4933 if _n_kwcontinue
!= null then
4934 v
.visit
(_n_kwcontinue
)
4939 redef meth n_kwdo
=(n
: TKwdo)
4946 redef meth n_block
=(n
: PExpr)
4954 private init empty_init
do end
4962 if n_kwdo
!= null then
4963 n_kwdo
.parent
= self
4966 if n_block
!= null then
4967 n_block
.parent
= self
4971 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
4973 assert old_child
!= null
4974 if _n_kwdo
== old_child
then
4975 if new_child
!= null then
4976 new_child
.parent
= self
4977 assert new_child
isa TKwdo
4984 if _n_block
== old_child
then
4985 if new_child
!= null then
4986 new_child
.parent
= self
4987 assert new_child
isa PExpr
4988 _n_block
= new_child
4996 redef meth visit_all
(v
: Visitor)
4998 if _n_kwdo
!= null then
5001 if _n_block
!= null then
5006 redef meth visit_all_reverse
(v
: Visitor)
5008 if _n_kwdo
!= null then
5011 if _n_block
!= null then
5017 redef meth n_kwif
=(n
: TKwif)
5024 redef meth n_expr
=(n
: PExpr)
5031 redef meth n_then
=(n
: PExpr)
5038 redef meth n_else
=(n
: PExpr)
5046 private init empty_init
do end
5056 if n_kwif
!= null then
5057 n_kwif
.parent
= self
5060 if n_expr
!= null then
5061 n_expr
.parent
= self
5064 if n_then
!= null then
5065 n_then
.parent
= self
5068 if n_else
!= null then
5069 n_else
.parent
= self
5073 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
5075 assert old_child
!= null
5076 if _n_kwif
== old_child
then
5077 if new_child
!= null then
5078 new_child
.parent
= self
5079 assert new_child
isa TKwif
5086 if _n_expr
== old_child
then
5087 if new_child
!= null then
5088 new_child
.parent
= self
5089 assert new_child
isa PExpr
5096 if _n_then
== old_child
then
5097 if new_child
!= null then
5098 new_child
.parent
= self
5099 assert new_child
isa PExpr
5106 if _n_else
== old_child
then
5107 if new_child
!= null then
5108 new_child
.parent
= self
5109 assert new_child
isa PExpr
5118 redef meth visit_all
(v
: Visitor)
5120 if _n_kwif
!= null then
5123 if _n_expr
!= null then
5126 if _n_then
!= null then
5129 if _n_else
!= null then
5134 redef meth visit_all_reverse
(v
: Visitor)
5136 if _n_kwif
!= null then
5139 if _n_expr
!= null then
5142 if _n_then
!= null then
5145 if _n_else
!= null then
5150 redef class AIfexprExpr
5151 redef meth n_kwif
=(n
: TKwif)
5158 redef meth n_expr
=(n
: PExpr)
5165 redef meth n_kwthen
=(n
: TKwthen)
5172 redef meth n_then
=(n
: PExpr)
5179 redef meth n_kwelse
=(n
: TKwelse)
5186 redef meth n_else
=(n
: PExpr)
5194 private init empty_init
do end
5196 init init_aifexprexpr
(
5206 if n_kwif
!= null then
5207 n_kwif
.parent
= self
5210 if n_expr
!= null then
5211 n_expr
.parent
= self
5213 _n_kwthen
= n_kwthen
5214 if n_kwthen
!= null then
5215 n_kwthen
.parent
= self
5218 if n_then
!= null then
5219 n_then
.parent
= self
5221 _n_kwelse
= n_kwelse
5222 if n_kwelse
!= null then
5223 n_kwelse
.parent
= self
5226 if n_else
!= null then
5227 n_else
.parent
= self
5231 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
5233 assert old_child
!= null
5234 if _n_kwif
== old_child
then
5235 if new_child
!= null then
5236 new_child
.parent
= self
5237 assert new_child
isa TKwif
5244 if _n_expr
== old_child
then
5245 if new_child
!= null then
5246 new_child
.parent
= self
5247 assert new_child
isa PExpr
5254 if _n_kwthen
== old_child
then
5255 if new_child
!= null then
5256 new_child
.parent
= self
5257 assert new_child
isa TKwthen
5258 _n_kwthen
= new_child
5264 if _n_then
== old_child
then
5265 if new_child
!= null then
5266 new_child
.parent
= self
5267 assert new_child
isa PExpr
5274 if _n_kwelse
== old_child
then
5275 if new_child
!= null then
5276 new_child
.parent
= self
5277 assert new_child
isa TKwelse
5278 _n_kwelse
= new_child
5284 if _n_else
== old_child
then
5285 if new_child
!= null then
5286 new_child
.parent
= self
5287 assert new_child
isa PExpr
5296 redef meth visit_all
(v
: Visitor)
5298 if _n_kwif
!= null then
5301 if _n_expr
!= null then
5304 if _n_kwthen
!= null then
5307 if _n_then
!= null then
5310 if _n_kwelse
!= null then
5313 if _n_else
!= null then
5318 redef meth visit_all_reverse
(v
: Visitor)
5320 if _n_kwif
!= null then
5323 if _n_expr
!= null then
5326 if _n_kwthen
!= null then
5329 if _n_then
!= null then
5332 if _n_kwelse
!= null then
5335 if _n_else
!= null then
5340 redef class AWhileExpr
5341 redef meth n_kwwhile
=(n
: TKwwhile)
5348 redef meth n_expr
=(n
: PExpr)
5355 redef meth n_kwdo
=(n
: TKwdo)
5362 redef meth n_block
=(n
: PExpr)
5370 private init empty_init
do end
5372 init init_awhileexpr
(
5373 n_kwwhile
: TKwwhile ,
5379 _n_kwwhile
= n_kwwhile
5380 if n_kwwhile
!= null then
5381 n_kwwhile
.parent
= self
5384 if n_expr
!= null then
5385 n_expr
.parent
= self
5388 if n_kwdo
!= null then
5389 n_kwdo
.parent
= self
5392 if n_block
!= null then
5393 n_block
.parent
= self
5397 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
5399 assert old_child
!= null
5400 if _n_kwwhile
== old_child
then
5401 if new_child
!= null then
5402 new_child
.parent
= self
5403 assert new_child
isa TKwwhile
5404 _n_kwwhile
= new_child
5410 if _n_expr
== old_child
then
5411 if new_child
!= null then
5412 new_child
.parent
= self
5413 assert new_child
isa PExpr
5420 if _n_kwdo
== old_child
then
5421 if new_child
!= null then
5422 new_child
.parent
= self
5423 assert new_child
isa TKwdo
5430 if _n_block
== old_child
then
5431 if new_child
!= null then
5432 new_child
.parent
= self
5433 assert new_child
isa PExpr
5434 _n_block
= new_child
5442 redef meth visit_all
(v
: Visitor)
5444 if _n_kwwhile
!= null then
5447 if _n_expr
!= null then
5450 if _n_kwdo
!= null then
5453 if _n_block
!= null then
5458 redef meth visit_all_reverse
(v
: Visitor)
5460 if _n_kwwhile
!= null then
5463 if _n_expr
!= null then
5466 if _n_kwdo
!= null then
5469 if _n_block
!= null then
5474 redef class AForExpr
5475 redef meth n_vardecl
=(n
: PExpr)
5482 redef meth n_kwdo
=(n
: TKwdo)
5489 redef meth n_block
=(n
: PExpr)
5497 private init empty_init
do end
5499 init init_aforexpr
(
5505 _n_vardecl
= n_vardecl
5506 if n_vardecl
!= null then
5507 n_vardecl
.parent
= self
5510 if n_kwdo
!= null then
5511 n_kwdo
.parent
= self
5514 if n_block
!= null then
5515 n_block
.parent
= self
5519 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
5521 assert old_child
!= null
5522 if _n_vardecl
== old_child
then
5523 if new_child
!= null then
5524 new_child
.parent
= self
5525 assert new_child
isa PExpr
5526 _n_vardecl
= new_child
5532 if _n_kwdo
== old_child
then
5533 if new_child
!= null then
5534 new_child
.parent
= self
5535 assert new_child
isa TKwdo
5542 if _n_block
== old_child
then
5543 if new_child
!= null then
5544 new_child
.parent
= self
5545 assert new_child
isa PExpr
5546 _n_block
= new_child
5554 redef meth visit_all
(v
: Visitor)
5556 if _n_vardecl
!= null then
5559 if _n_kwdo
!= null then
5562 if _n_block
!= null then
5567 redef meth visit_all_reverse
(v
: Visitor)
5569 if _n_vardecl
!= null then
5572 if _n_kwdo
!= null then
5575 if _n_block
!= null then
5580 redef class AForVardeclExpr
5581 redef meth n_kwfor
=(n
: TKwfor)
5588 redef meth n_id
=(n
: TId)
5595 redef meth n_expr
=(n
: PExpr)
5603 private init empty_init
do end
5605 init init_aforvardeclexpr
(
5612 if n_kwfor
!= null then
5613 n_kwfor
.parent
= self
5616 if n_id
!= null then
5620 if n_expr
!= null then
5621 n_expr
.parent
= self
5625 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
5627 assert old_child
!= null
5628 if _n_kwfor
== old_child
then
5629 if new_child
!= null then
5630 new_child
.parent
= self
5631 assert new_child
isa TKwfor
5632 _n_kwfor
= new_child
5638 if _n_id
== old_child
then
5639 if new_child
!= null then
5640 new_child
.parent
= self
5641 assert new_child
isa TId
5648 if _n_expr
== old_child
then
5649 if new_child
!= null then
5650 new_child
.parent
= self
5651 assert new_child
isa PExpr
5660 redef meth visit_all
(v
: Visitor)
5662 if _n_kwfor
!= null then
5665 if _n_id
!= null then
5668 if _n_expr
!= null then
5673 redef meth visit_all_reverse
(v
: Visitor)
5675 if _n_kwfor
!= null then
5678 if _n_id
!= null then
5681 if _n_expr
!= null then
5686 redef class AAssertExpr
5687 redef meth n_kwassert
=(n
: TKwassert)
5694 redef meth n_id
=(n
: TId)
5701 redef meth n_expr
=(n
: PExpr)
5709 private init empty_init
do end
5711 init init_aassertexpr
(
5712 n_kwassert
: TKwassert ,
5717 _n_kwassert
= n_kwassert
5718 if n_kwassert
!= null then
5719 n_kwassert
.parent
= self
5722 if n_id
!= null then
5726 if n_expr
!= null then
5727 n_expr
.parent
= self
5731 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
5733 assert old_child
!= null
5734 if _n_kwassert
== old_child
then
5735 if new_child
!= null then
5736 new_child
.parent
= self
5737 assert new_child
isa TKwassert
5738 _n_kwassert
= new_child
5744 if _n_id
== old_child
then
5745 if new_child
!= null then
5746 new_child
.parent
= self
5747 assert new_child
isa TId
5754 if _n_expr
== old_child
then
5755 if new_child
!= null then
5756 new_child
.parent
= self
5757 assert new_child
isa PExpr
5766 redef meth visit_all
(v
: Visitor)
5768 if _n_kwassert
!= null then
5769 v
.visit
(_n_kwassert
)
5771 if _n_id
!= null then
5774 if _n_expr
!= null then
5779 redef meth visit_all_reverse
(v
: Visitor)
5781 if _n_kwassert
!= null then
5782 v
.visit
(_n_kwassert
)
5784 if _n_id
!= null then
5787 if _n_expr
!= null then
5792 redef class AOnceExpr
5793 redef meth n_kwonce
=(n
: TKwonce)
5800 redef meth n_expr
=(n
: PExpr)
5808 private init empty_init
do end
5810 init init_aonceexpr
(
5815 _n_kwonce
= n_kwonce
5816 if n_kwonce
!= null then
5817 n_kwonce
.parent
= self
5820 if n_expr
!= null then
5821 n_expr
.parent
= self
5825 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
5827 assert old_child
!= null
5828 if _n_kwonce
== old_child
then
5829 if new_child
!= null then
5830 new_child
.parent
= self
5831 assert new_child
isa TKwonce
5832 _n_kwonce
= new_child
5838 if _n_expr
== old_child
then
5839 if new_child
!= null then
5840 new_child
.parent
= self
5841 assert new_child
isa PExpr
5850 redef meth visit_all
(v
: Visitor)
5852 if _n_kwonce
!= null then
5855 if _n_expr
!= null then
5860 redef meth visit_all_reverse
(v
: Visitor)
5862 if _n_kwonce
!= null then
5865 if _n_expr
!= null then
5870 redef class ASendExpr
5871 redef meth n_expr
=(n
: PExpr)
5879 private init empty_init
do end
5881 init init_asendexpr
(
5886 if n_expr
!= null then
5887 n_expr
.parent
= self
5891 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
5893 assert old_child
!= null
5894 if _n_expr
== old_child
then
5895 if new_child
!= null then
5896 new_child
.parent
= self
5897 assert new_child
isa PExpr
5906 redef meth visit_all
(v
: Visitor)
5908 if _n_expr
!= null then
5913 redef meth visit_all_reverse
(v
: Visitor)
5915 if _n_expr
!= null then
5920 redef class ABinopExpr
5921 redef meth n_expr
=(n
: PExpr)
5928 redef meth n_expr2
=(n
: PExpr)
5936 private init empty_init
do end
5938 init init_abinopexpr
(
5944 if n_expr
!= null then
5945 n_expr
.parent
= self
5948 if n_expr2
!= null then
5949 n_expr2
.parent
= self
5953 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
5955 assert old_child
!= null
5956 if _n_expr
== old_child
then
5957 if new_child
!= null then
5958 new_child
.parent
= self
5959 assert new_child
isa PExpr
5966 if _n_expr2
== old_child
then
5967 if new_child
!= null then
5968 new_child
.parent
= self
5969 assert new_child
isa PExpr
5970 _n_expr2
= new_child
5978 redef meth visit_all
(v
: Visitor)
5980 if _n_expr
!= null then
5983 if _n_expr2
!= null then
5988 redef meth visit_all_reverse
(v
: Visitor)
5990 if _n_expr
!= null then
5993 if _n_expr2
!= null then
5999 redef meth n_expr
=(n
: PExpr)
6006 redef meth n_expr2
=(n
: PExpr)
6014 private init empty_init
do end
6022 if n_expr
!= null then
6023 n_expr
.parent
= self
6026 if n_expr2
!= null then
6027 n_expr2
.parent
= self
6031 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
6033 assert old_child
!= null
6034 if _n_expr
== old_child
then
6035 if new_child
!= null then
6036 new_child
.parent
= self
6037 assert new_child
isa PExpr
6044 if _n_expr2
== old_child
then
6045 if new_child
!= null then
6046 new_child
.parent
= self
6047 assert new_child
isa PExpr
6048 _n_expr2
= new_child
6056 redef meth visit_all
(v
: Visitor)
6058 if _n_expr
!= null then
6061 if _n_expr2
!= null then
6066 redef meth visit_all_reverse
(v
: Visitor)
6068 if _n_expr
!= null then
6071 if _n_expr2
!= null then
6076 redef class AAndExpr
6077 redef meth n_expr
=(n
: PExpr)
6084 redef meth n_expr2
=(n
: PExpr)
6092 private init empty_init
do end
6094 init init_aandexpr
(
6100 if n_expr
!= null then
6101 n_expr
.parent
= self
6104 if n_expr2
!= null then
6105 n_expr2
.parent
= self
6109 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
6111 assert old_child
!= null
6112 if _n_expr
== old_child
then
6113 if new_child
!= null then
6114 new_child
.parent
= self
6115 assert new_child
isa PExpr
6122 if _n_expr2
== old_child
then
6123 if new_child
!= null then
6124 new_child
.parent
= self
6125 assert new_child
isa PExpr
6126 _n_expr2
= new_child
6134 redef meth visit_all
(v
: Visitor)
6136 if _n_expr
!= null then
6139 if _n_expr2
!= null then
6144 redef meth visit_all_reverse
(v
: Visitor)
6146 if _n_expr
!= null then
6149 if _n_expr2
!= null then
6154 redef class ANotExpr
6155 redef meth n_kwnot
=(n
: TKwnot)
6162 redef meth n_expr
=(n
: PExpr)
6170 private init empty_init
do end
6172 init init_anotexpr
(
6178 if n_kwnot
!= null then
6179 n_kwnot
.parent
= self
6182 if n_expr
!= null then
6183 n_expr
.parent
= self
6187 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
6189 assert old_child
!= null
6190 if _n_kwnot
== old_child
then
6191 if new_child
!= null then
6192 new_child
.parent
= self
6193 assert new_child
isa TKwnot
6194 _n_kwnot
= new_child
6200 if _n_expr
== old_child
then
6201 if new_child
!= null then
6202 new_child
.parent
= self
6203 assert new_child
isa PExpr
6212 redef meth visit_all
(v
: Visitor)
6214 if _n_kwnot
!= null then
6217 if _n_expr
!= null then
6222 redef meth visit_all_reverse
(v
: Visitor)
6224 if _n_kwnot
!= null then
6227 if _n_expr
!= null then
6233 redef meth n_expr
=(n
: PExpr)
6240 redef meth n_expr2
=(n
: PExpr)
6248 private init empty_init
do end
6256 if n_expr
!= null then
6257 n_expr
.parent
= self
6260 if n_expr2
!= null then
6261 n_expr2
.parent
= self
6265 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
6267 assert old_child
!= null
6268 if _n_expr
== old_child
then
6269 if new_child
!= null then
6270 new_child
.parent
= self
6271 assert new_child
isa PExpr
6278 if _n_expr2
== old_child
then
6279 if new_child
!= null then
6280 new_child
.parent
= self
6281 assert new_child
isa PExpr
6282 _n_expr2
= new_child
6290 redef meth visit_all
(v
: Visitor)
6292 if _n_expr
!= null then
6295 if _n_expr2
!= null then
6300 redef meth visit_all_reverse
(v
: Visitor)
6302 if _n_expr
!= null then
6305 if _n_expr2
!= null then
6311 redef meth n_expr
=(n
: PExpr)
6318 redef meth n_expr2
=(n
: PExpr)
6326 private init empty_init
do end
6334 if n_expr
!= null then
6335 n_expr
.parent
= self
6338 if n_expr2
!= null then
6339 n_expr2
.parent
= self
6343 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
6345 assert old_child
!= null
6346 if _n_expr
== old_child
then
6347 if new_child
!= null then
6348 new_child
.parent
= self
6349 assert new_child
isa PExpr
6356 if _n_expr2
== old_child
then
6357 if new_child
!= null then
6358 new_child
.parent
= self
6359 assert new_child
isa PExpr
6360 _n_expr2
= new_child
6368 redef meth visit_all
(v
: Visitor)
6370 if _n_expr
!= null then
6373 if _n_expr2
!= null then
6378 redef meth visit_all_reverse
(v
: Visitor)
6380 if _n_expr
!= null then
6383 if _n_expr2
!= null then
6389 redef meth n_expr
=(n
: PExpr)
6396 redef meth n_expr2
=(n
: PExpr)
6404 private init empty_init
do end
6412 if n_expr
!= null then
6413 n_expr
.parent
= self
6416 if n_expr2
!= null then
6417 n_expr2
.parent
= self
6421 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
6423 assert old_child
!= null
6424 if _n_expr
== old_child
then
6425 if new_child
!= null then
6426 new_child
.parent
= self
6427 assert new_child
isa PExpr
6434 if _n_expr2
== old_child
then
6435 if new_child
!= null then
6436 new_child
.parent
= self
6437 assert new_child
isa PExpr
6438 _n_expr2
= new_child
6446 redef meth visit_all
(v
: Visitor)
6448 if _n_expr
!= null then
6451 if _n_expr2
!= null then
6456 redef meth visit_all_reverse
(v
: Visitor)
6458 if _n_expr
!= null then
6461 if _n_expr2
!= null then
6467 redef meth n_expr
=(n
: PExpr)
6474 redef meth n_expr2
=(n
: PExpr)
6482 private init empty_init
do end
6490 if n_expr
!= null then
6491 n_expr
.parent
= self
6494 if n_expr2
!= null then
6495 n_expr2
.parent
= self
6499 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
6501 assert old_child
!= null
6502 if _n_expr
== old_child
then
6503 if new_child
!= null then
6504 new_child
.parent
= self
6505 assert new_child
isa PExpr
6512 if _n_expr2
== old_child
then
6513 if new_child
!= null then
6514 new_child
.parent
= self
6515 assert new_child
isa PExpr
6516 _n_expr2
= new_child
6524 redef meth visit_all
(v
: Visitor)
6526 if _n_expr
!= null then
6529 if _n_expr2
!= null then
6534 redef meth visit_all_reverse
(v
: Visitor)
6536 if _n_expr
!= null then
6539 if _n_expr2
!= null then
6545 redef meth n_expr
=(n
: PExpr)
6552 redef meth n_expr2
=(n
: PExpr)
6560 private init empty_init
do end
6568 if n_expr
!= null then
6569 n_expr
.parent
= self
6572 if n_expr2
!= null then
6573 n_expr2
.parent
= self
6577 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
6579 assert old_child
!= null
6580 if _n_expr
== old_child
then
6581 if new_child
!= null then
6582 new_child
.parent
= self
6583 assert new_child
isa PExpr
6590 if _n_expr2
== old_child
then
6591 if new_child
!= null then
6592 new_child
.parent
= self
6593 assert new_child
isa PExpr
6594 _n_expr2
= new_child
6602 redef meth visit_all
(v
: Visitor)
6604 if _n_expr
!= null then
6607 if _n_expr2
!= null then
6612 redef meth visit_all_reverse
(v
: Visitor)
6614 if _n_expr
!= null then
6617 if _n_expr2
!= null then
6623 redef meth n_expr
=(n
: PExpr)
6630 redef meth n_expr2
=(n
: PExpr)
6638 private init empty_init
do end
6646 if n_expr
!= null then
6647 n_expr
.parent
= self
6650 if n_expr2
!= null then
6651 n_expr2
.parent
= self
6655 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
6657 assert old_child
!= null
6658 if _n_expr
== old_child
then
6659 if new_child
!= null then
6660 new_child
.parent
= self
6661 assert new_child
isa PExpr
6668 if _n_expr2
== old_child
then
6669 if new_child
!= null then
6670 new_child
.parent
= self
6671 assert new_child
isa PExpr
6672 _n_expr2
= new_child
6680 redef meth visit_all
(v
: Visitor)
6682 if _n_expr
!= null then
6685 if _n_expr2
!= null then
6690 redef meth visit_all_reverse
(v
: Visitor)
6692 if _n_expr
!= null then
6695 if _n_expr2
!= null then
6701 redef meth n_expr
=(n
: PExpr)
6708 redef meth n_expr2
=(n
: PExpr)
6716 private init empty_init
do end
6724 if n_expr
!= null then
6725 n_expr
.parent
= self
6728 if n_expr2
!= null then
6729 n_expr2
.parent
= self
6733 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
6735 assert old_child
!= null
6736 if _n_expr
== old_child
then
6737 if new_child
!= null then
6738 new_child
.parent
= self
6739 assert new_child
isa PExpr
6746 if _n_expr2
== old_child
then
6747 if new_child
!= null then
6748 new_child
.parent
= self
6749 assert new_child
isa PExpr
6750 _n_expr2
= new_child
6758 redef meth visit_all
(v
: Visitor)
6760 if _n_expr
!= null then
6763 if _n_expr2
!= null then
6768 redef meth visit_all_reverse
(v
: Visitor)
6770 if _n_expr
!= null then
6773 if _n_expr2
!= null then
6778 redef class AIsaExpr
6779 redef meth n_expr
=(n
: PExpr)
6786 redef meth n_type
=(n
: PType)
6794 private init empty_init
do end
6796 init init_aisaexpr
(
6802 if n_expr
!= null then
6803 n_expr
.parent
= self
6806 if n_type
!= null then
6807 n_type
.parent
= self
6811 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
6813 assert old_child
!= null
6814 if _n_expr
== old_child
then
6815 if new_child
!= null then
6816 new_child
.parent
= self
6817 assert new_child
isa PExpr
6824 if _n_type
== old_child
then
6825 if new_child
!= null then
6826 new_child
.parent
= self
6827 assert new_child
isa PType
6836 redef meth visit_all
(v
: Visitor)
6838 if _n_expr
!= null then
6841 if _n_type
!= null then
6846 redef meth visit_all_reverse
(v
: Visitor)
6848 if _n_expr
!= null then
6851 if _n_type
!= null then
6856 redef class APlusExpr
6857 redef meth n_expr
=(n
: PExpr)
6864 redef meth n_expr2
=(n
: PExpr)
6872 private init empty_init
do end
6874 init init_aplusexpr
(
6880 if n_expr
!= null then
6881 n_expr
.parent
= self
6884 if n_expr2
!= null then
6885 n_expr2
.parent
= self
6889 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
6891 assert old_child
!= null
6892 if _n_expr
== old_child
then
6893 if new_child
!= null then
6894 new_child
.parent
= self
6895 assert new_child
isa PExpr
6902 if _n_expr2
== old_child
then
6903 if new_child
!= null then
6904 new_child
.parent
= self
6905 assert new_child
isa PExpr
6906 _n_expr2
= new_child
6914 redef meth visit_all
(v
: Visitor)
6916 if _n_expr
!= null then
6919 if _n_expr2
!= null then
6924 redef meth visit_all_reverse
(v
: Visitor)
6926 if _n_expr
!= null then
6929 if _n_expr2
!= null then
6934 redef class AMinusExpr
6935 redef meth n_expr
=(n
: PExpr)
6942 redef meth n_expr2
=(n
: PExpr)
6950 private init empty_init
do end
6952 init init_aminusexpr
(
6958 if n_expr
!= null then
6959 n_expr
.parent
= self
6962 if n_expr2
!= null then
6963 n_expr2
.parent
= self
6967 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
6969 assert old_child
!= null
6970 if _n_expr
== old_child
then
6971 if new_child
!= null then
6972 new_child
.parent
= self
6973 assert new_child
isa PExpr
6980 if _n_expr2
== old_child
then
6981 if new_child
!= null then
6982 new_child
.parent
= self
6983 assert new_child
isa PExpr
6984 _n_expr2
= new_child
6992 redef meth visit_all
(v
: Visitor)
6994 if _n_expr
!= null then
6997 if _n_expr2
!= null then
7002 redef meth visit_all_reverse
(v
: Visitor)
7004 if _n_expr
!= null then
7007 if _n_expr2
!= null then
7012 redef class AStarshipExpr
7013 redef meth n_expr
=(n
: PExpr)
7020 redef meth n_expr2
=(n
: PExpr)
7028 private init empty_init
do end
7030 init init_astarshipexpr
(
7036 if n_expr
!= null then
7037 n_expr
.parent
= self
7040 if n_expr2
!= null then
7041 n_expr2
.parent
= self
7045 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
7047 assert old_child
!= null
7048 if _n_expr
== old_child
then
7049 if new_child
!= null then
7050 new_child
.parent
= self
7051 assert new_child
isa PExpr
7058 if _n_expr2
== old_child
then
7059 if new_child
!= null then
7060 new_child
.parent
= self
7061 assert new_child
isa PExpr
7062 _n_expr2
= new_child
7070 redef meth visit_all
(v
: Visitor)
7072 if _n_expr
!= null then
7075 if _n_expr2
!= null then
7080 redef meth visit_all_reverse
(v
: Visitor)
7082 if _n_expr
!= null then
7085 if _n_expr2
!= null then
7090 redef class AStarExpr
7091 redef meth n_expr
=(n
: PExpr)
7098 redef meth n_expr2
=(n
: PExpr)
7106 private init empty_init
do end
7108 init init_astarexpr
(
7114 if n_expr
!= null then
7115 n_expr
.parent
= self
7118 if n_expr2
!= null then
7119 n_expr2
.parent
= self
7123 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
7125 assert old_child
!= null
7126 if _n_expr
== old_child
then
7127 if new_child
!= null then
7128 new_child
.parent
= self
7129 assert new_child
isa PExpr
7136 if _n_expr2
== old_child
then
7137 if new_child
!= null then
7138 new_child
.parent
= self
7139 assert new_child
isa PExpr
7140 _n_expr2
= new_child
7148 redef meth visit_all
(v
: Visitor)
7150 if _n_expr
!= null then
7153 if _n_expr2
!= null then
7158 redef meth visit_all_reverse
(v
: Visitor)
7160 if _n_expr
!= null then
7163 if _n_expr2
!= null then
7168 redef class ASlashExpr
7169 redef meth n_expr
=(n
: PExpr)
7176 redef meth n_expr2
=(n
: PExpr)
7184 private init empty_init
do end
7186 init init_aslashexpr
(
7192 if n_expr
!= null then
7193 n_expr
.parent
= self
7196 if n_expr2
!= null then
7197 n_expr2
.parent
= self
7201 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
7203 assert old_child
!= null
7204 if _n_expr
== old_child
then
7205 if new_child
!= null then
7206 new_child
.parent
= self
7207 assert new_child
isa PExpr
7214 if _n_expr2
== old_child
then
7215 if new_child
!= null then
7216 new_child
.parent
= self
7217 assert new_child
isa PExpr
7218 _n_expr2
= new_child
7226 redef meth visit_all
(v
: Visitor)
7228 if _n_expr
!= null then
7231 if _n_expr2
!= null then
7236 redef meth visit_all_reverse
(v
: Visitor)
7238 if _n_expr
!= null then
7241 if _n_expr2
!= null then
7246 redef class APercentExpr
7247 redef meth n_expr
=(n
: PExpr)
7254 redef meth n_expr2
=(n
: PExpr)
7262 private init empty_init
do end
7264 init init_apercentexpr
(
7270 if n_expr
!= null then
7271 n_expr
.parent
= self
7274 if n_expr2
!= null then
7275 n_expr2
.parent
= self
7279 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
7281 assert old_child
!= null
7282 if _n_expr
== old_child
then
7283 if new_child
!= null then
7284 new_child
.parent
= self
7285 assert new_child
isa PExpr
7292 if _n_expr2
== old_child
then
7293 if new_child
!= null then
7294 new_child
.parent
= self
7295 assert new_child
isa PExpr
7296 _n_expr2
= new_child
7304 redef meth visit_all
(v
: Visitor)
7306 if _n_expr
!= null then
7309 if _n_expr2
!= null then
7314 redef meth visit_all_reverse
(v
: Visitor)
7316 if _n_expr
!= null then
7319 if _n_expr2
!= null then
7324 redef class AUminusExpr
7325 redef meth n_minus
=(n
: TMinus)
7332 redef meth n_expr
=(n
: PExpr)
7340 private init empty_init
do end
7342 init init_auminusexpr
(
7348 if n_minus
!= null then
7349 n_minus
.parent
= self
7352 if n_expr
!= null then
7353 n_expr
.parent
= self
7357 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
7359 assert old_child
!= null
7360 if _n_minus
== old_child
then
7361 if new_child
!= null then
7362 new_child
.parent
= self
7363 assert new_child
isa TMinus
7364 _n_minus
= new_child
7370 if _n_expr
== old_child
then
7371 if new_child
!= null then
7372 new_child
.parent
= self
7373 assert new_child
isa PExpr
7382 redef meth visit_all
(v
: Visitor)
7384 if _n_minus
!= null then
7387 if _n_expr
!= null then
7392 redef meth visit_all_reverse
(v
: Visitor)
7394 if _n_minus
!= null then
7397 if _n_expr
!= null then
7402 redef class ANewExpr
7403 redef meth n_kwnew
=(n
: TKwnew)
7410 redef meth n_type
=(n
: PType)
7417 redef meth n_id
=(n
: TId)
7425 private init empty_init
do end
7427 init init_anewexpr
(
7431 n_args
: Array[Object] # Should be Array[PExpr]
7435 if n_kwnew
!= null then
7436 n_kwnew
.parent
= self
7439 if n_type
!= null then
7440 n_type
.parent
= self
7443 if n_id
!= null then
7446 _n_args
= new List[PExpr]
7454 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
7456 assert old_child
!= null
7457 if _n_kwnew
== old_child
then
7458 if new_child
!= null then
7459 new_child
.parent
= self
7460 assert new_child
isa TKwnew
7461 _n_kwnew
= new_child
7467 if _n_type
== old_child
then
7468 if new_child
!= null then
7469 new_child
.parent
= self
7470 assert new_child
isa PType
7477 if _n_id
== old_child
then
7478 if new_child
!= null then
7479 new_child
.parent
= self
7480 assert new_child
isa TId
7487 for i
in [0.._n_args
.length
[ do
7488 if _n_args
[i
] == old_child
then
7489 if new_child
!= null then
7490 assert new_child
isa PExpr
7491 _n_args
[i
] = new_child
7492 new_child
.parent
= self
7494 _n_args
.remove_at
(i
)
7501 redef meth visit_all
(v
: Visitor)
7503 if _n_kwnew
!= null then
7506 if _n_type
!= null then
7509 if _n_id
!= null then
7517 redef meth visit_all_reverse
(v
: Visitor)
7519 if _n_kwnew
!= null then
7522 if _n_type
!= null then
7525 if _n_id
!= null then
7529 var i
= _n_args
.length
7537 redef class AAttrExpr
7538 redef meth n_expr
=(n
: PExpr)
7545 redef meth n_id
=(n
: TAttrid)
7553 private init empty_init
do end
7555 init init_aattrexpr
(
7561 if n_expr
!= null then
7562 n_expr
.parent
= self
7565 if n_id
!= null then
7570 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
7572 assert old_child
!= null
7573 if _n_expr
== old_child
then
7574 if new_child
!= null then
7575 new_child
.parent
= self
7576 assert new_child
isa PExpr
7583 if _n_id
== old_child
then
7584 if new_child
!= null then
7585 new_child
.parent
= self
7586 assert new_child
isa TAttrid
7595 redef meth visit_all
(v
: Visitor)
7597 if _n_expr
!= null then
7600 if _n_id
!= null then
7605 redef meth visit_all_reverse
(v
: Visitor)
7607 if _n_expr
!= null then
7610 if _n_id
!= null then
7615 redef class AAttrAssignExpr
7616 redef meth n_expr
=(n
: PExpr)
7623 redef meth n_id
=(n
: TAttrid)
7630 redef meth n_assign
=(n
: TAssign)
7637 redef meth n_value
=(n
: PExpr)
7645 private init empty_init
do end
7647 init init_aattrassignexpr
(
7655 if n_expr
!= null then
7656 n_expr
.parent
= self
7659 if n_id
!= null then
7662 _n_assign
= n_assign
7663 if n_assign
!= null then
7664 n_assign
.parent
= self
7667 if n_value
!= null then
7668 n_value
.parent
= self
7672 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
7674 assert old_child
!= null
7675 if _n_expr
== old_child
then
7676 if new_child
!= null then
7677 new_child
.parent
= self
7678 assert new_child
isa PExpr
7685 if _n_id
== old_child
then
7686 if new_child
!= null then
7687 new_child
.parent
= self
7688 assert new_child
isa TAttrid
7695 if _n_assign
== old_child
then
7696 if new_child
!= null then
7697 new_child
.parent
= self
7698 assert new_child
isa TAssign
7699 _n_assign
= new_child
7705 if _n_value
== old_child
then
7706 if new_child
!= null then
7707 new_child
.parent
= self
7708 assert new_child
isa PExpr
7709 _n_value
= new_child
7717 redef meth visit_all
(v
: Visitor)
7719 if _n_expr
!= null then
7722 if _n_id
!= null then
7725 if _n_assign
!= null then
7728 if _n_value
!= null then
7733 redef meth visit_all_reverse
(v
: Visitor)
7735 if _n_expr
!= null then
7738 if _n_id
!= null then
7741 if _n_assign
!= null then
7744 if _n_value
!= null then
7749 redef class AAttrReassignExpr
7750 redef meth n_expr
=(n
: PExpr)
7757 redef meth n_id
=(n
: TAttrid)
7764 redef meth n_assign_op
=(n
: PAssignOp)
7771 redef meth n_value
=(n
: PExpr)
7779 private init empty_init
do end
7781 init init_aattrreassignexpr
(
7784 n_assign_op
: PAssignOp ,
7789 if n_expr
!= null then
7790 n_expr
.parent
= self
7793 if n_id
!= null then
7796 _n_assign_op
= n_assign_op
7797 if n_assign_op
!= null then
7798 n_assign_op
.parent
= self
7801 if n_value
!= null then
7802 n_value
.parent
= self
7806 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
7808 assert old_child
!= null
7809 if _n_expr
== old_child
then
7810 if new_child
!= null then
7811 new_child
.parent
= self
7812 assert new_child
isa PExpr
7819 if _n_id
== old_child
then
7820 if new_child
!= null then
7821 new_child
.parent
= self
7822 assert new_child
isa TAttrid
7829 if _n_assign_op
== old_child
then
7830 if new_child
!= null then
7831 new_child
.parent
= self
7832 assert new_child
isa PAssignOp
7833 _n_assign_op
= new_child
7839 if _n_value
== old_child
then
7840 if new_child
!= null then
7841 new_child
.parent
= self
7842 assert new_child
isa PExpr
7843 _n_value
= new_child
7851 redef meth visit_all
(v
: Visitor)
7853 if _n_expr
!= null then
7856 if _n_id
!= null then
7859 if _n_assign_op
!= null then
7860 v
.visit
(_n_assign_op
)
7862 if _n_value
!= null then
7867 redef meth visit_all_reverse
(v
: Visitor)
7869 if _n_expr
!= null then
7872 if _n_id
!= null then
7875 if _n_assign_op
!= null then
7876 v
.visit
(_n_assign_op
)
7878 if _n_value
!= null then
7883 redef class ACallExpr
7884 redef meth n_expr
=(n
: PExpr)
7891 redef meth n_id
=(n
: TId)
7899 private init empty_init
do end
7901 init init_acallexpr
(
7904 n_args
: Array[Object] # Should be Array[PExpr]
7908 if n_expr
!= null then
7909 n_expr
.parent
= self
7912 if n_id
!= null then
7915 _n_args
= new List[PExpr]
7923 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
7925 assert old_child
!= null
7926 if _n_expr
== old_child
then
7927 if new_child
!= null then
7928 new_child
.parent
= self
7929 assert new_child
isa PExpr
7936 if _n_id
== old_child
then
7937 if new_child
!= null then
7938 new_child
.parent
= self
7939 assert new_child
isa TId
7946 for i
in [0.._n_args
.length
[ do
7947 if _n_args
[i
] == old_child
then
7948 if new_child
!= null then
7949 assert new_child
isa PExpr
7950 _n_args
[i
] = new_child
7951 new_child
.parent
= self
7953 _n_args
.remove_at
(i
)
7960 redef meth visit_all
(v
: Visitor)
7962 if _n_expr
!= null then
7965 if _n_id
!= null then
7973 redef meth visit_all_reverse
(v
: Visitor)
7975 if _n_expr
!= null then
7978 if _n_id
!= null then
7982 var i
= _n_args
.length
7990 redef class ACallAssignExpr
7991 redef meth n_expr
=(n
: PExpr)
7998 redef meth n_id
=(n
: TId)
8005 redef meth n_assign
=(n
: TAssign)
8012 redef meth n_value
=(n
: PExpr)
8020 private init empty_init
do end
8022 init init_acallassignexpr
(
8025 n_args
: Array[Object] , # Should be Array[PExpr]
8031 if n_expr
!= null then
8032 n_expr
.parent
= self
8035 if n_id
!= null then
8038 _n_args
= new List[PExpr]
8044 _n_assign
= n_assign
8045 if n_assign
!= null then
8046 n_assign
.parent
= self
8049 if n_value
!= null then
8050 n_value
.parent
= self
8054 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
8056 assert old_child
!= null
8057 if _n_expr
== old_child
then
8058 if new_child
!= null then
8059 new_child
.parent
= self
8060 assert new_child
isa PExpr
8067 if _n_id
== old_child
then
8068 if new_child
!= null then
8069 new_child
.parent
= self
8070 assert new_child
isa TId
8077 for i
in [0.._n_args
.length
[ do
8078 if _n_args
[i
] == old_child
then
8079 if new_child
!= null then
8080 assert new_child
isa PExpr
8081 _n_args
[i
] = new_child
8082 new_child
.parent
= self
8084 _n_args
.remove_at
(i
)
8089 if _n_assign
== old_child
then
8090 if new_child
!= null then
8091 new_child
.parent
= self
8092 assert new_child
isa TAssign
8093 _n_assign
= new_child
8099 if _n_value
== old_child
then
8100 if new_child
!= null then
8101 new_child
.parent
= self
8102 assert new_child
isa PExpr
8103 _n_value
= new_child
8111 redef meth visit_all
(v
: Visitor)
8113 if _n_expr
!= null then
8116 if _n_id
!= null then
8122 if _n_assign
!= null then
8125 if _n_value
!= null then
8130 redef meth visit_all_reverse
(v
: Visitor)
8132 if _n_expr
!= null then
8135 if _n_id
!= null then
8139 var i
= _n_args
.length
8145 if _n_assign
!= null then
8148 if _n_value
!= null then
8153 redef class ACallReassignExpr
8154 redef meth n_expr
=(n
: PExpr)
8161 redef meth n_id
=(n
: TId)
8168 redef meth n_assign_op
=(n
: PAssignOp)
8175 redef meth n_value
=(n
: PExpr)
8183 private init empty_init
do end
8185 init init_acallreassignexpr
(
8188 n_args
: Array[Object] , # Should be Array[PExpr]
8189 n_assign_op
: PAssignOp ,
8194 if n_expr
!= null then
8195 n_expr
.parent
= self
8198 if n_id
!= null then
8201 _n_args
= new List[PExpr]
8207 _n_assign_op
= n_assign_op
8208 if n_assign_op
!= null then
8209 n_assign_op
.parent
= self
8212 if n_value
!= null then
8213 n_value
.parent
= self
8217 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
8219 assert old_child
!= null
8220 if _n_expr
== old_child
then
8221 if new_child
!= null then
8222 new_child
.parent
= self
8223 assert new_child
isa PExpr
8230 if _n_id
== old_child
then
8231 if new_child
!= null then
8232 new_child
.parent
= self
8233 assert new_child
isa TId
8240 for i
in [0.._n_args
.length
[ do
8241 if _n_args
[i
] == old_child
then
8242 if new_child
!= null then
8243 assert new_child
isa PExpr
8244 _n_args
[i
] = new_child
8245 new_child
.parent
= self
8247 _n_args
.remove_at
(i
)
8252 if _n_assign_op
== old_child
then
8253 if new_child
!= null then
8254 new_child
.parent
= self
8255 assert new_child
isa PAssignOp
8256 _n_assign_op
= new_child
8262 if _n_value
== old_child
then
8263 if new_child
!= null then
8264 new_child
.parent
= self
8265 assert new_child
isa PExpr
8266 _n_value
= new_child
8274 redef meth visit_all
(v
: Visitor)
8276 if _n_expr
!= null then
8279 if _n_id
!= null then
8285 if _n_assign_op
!= null then
8286 v
.visit
(_n_assign_op
)
8288 if _n_value
!= null then
8293 redef meth visit_all_reverse
(v
: Visitor)
8295 if _n_expr
!= null then
8298 if _n_id
!= null then
8302 var i
= _n_args
.length
8308 if _n_assign_op
!= null then
8309 v
.visit
(_n_assign_op
)
8311 if _n_value
!= null then
8316 redef class ASuperExpr
8317 redef meth n_qualified
=(n
: PQualified)
8324 redef meth n_kwsuper
=(n
: TKwsuper)
8332 private init empty_init
do end
8334 init init_asuperexpr
(
8335 n_qualified
: PQualified ,
8336 n_kwsuper
: TKwsuper ,
8337 n_args
: Array[Object] # Should be Array[PExpr]
8340 _n_qualified
= n_qualified
8341 if n_qualified
!= null then
8342 n_qualified
.parent
= self
8344 _n_kwsuper
= n_kwsuper
8345 if n_kwsuper
!= null then
8346 n_kwsuper
.parent
= self
8348 _n_args
= new List[PExpr]
8356 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
8358 assert old_child
!= null
8359 if _n_qualified
== old_child
then
8360 if new_child
!= null then
8361 new_child
.parent
= self
8362 assert new_child
isa PQualified
8363 _n_qualified
= new_child
8369 if _n_kwsuper
== old_child
then
8370 if new_child
!= null then
8371 new_child
.parent
= self
8372 assert new_child
isa TKwsuper
8373 _n_kwsuper
= new_child
8379 for i
in [0.._n_args
.length
[ do
8380 if _n_args
[i
] == old_child
then
8381 if new_child
!= null then
8382 assert new_child
isa PExpr
8383 _n_args
[i
] = new_child
8384 new_child
.parent
= self
8386 _n_args
.remove_at
(i
)
8393 redef meth visit_all
(v
: Visitor)
8395 if _n_qualified
!= null then
8396 v
.visit
(_n_qualified
)
8398 if _n_kwsuper
!= null then
8406 redef meth visit_all_reverse
(v
: Visitor)
8408 if _n_qualified
!= null then
8409 v
.visit
(_n_qualified
)
8411 if _n_kwsuper
!= null then
8415 var i
= _n_args
.length
8423 redef class AInitExpr
8424 redef meth n_expr
=(n
: PExpr)
8431 redef meth n_kwinit
=(n
: TKwinit)
8439 private init empty_init
do end
8441 init init_ainitexpr
(
8444 n_args
: Array[Object] # Should be Array[PExpr]
8448 if n_expr
!= null then
8449 n_expr
.parent
= self
8451 _n_kwinit
= n_kwinit
8452 if n_kwinit
!= null then
8453 n_kwinit
.parent
= self
8455 _n_args
= new List[PExpr]
8463 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
8465 assert old_child
!= null
8466 if _n_expr
== old_child
then
8467 if new_child
!= null then
8468 new_child
.parent
= self
8469 assert new_child
isa PExpr
8476 if _n_kwinit
== old_child
then
8477 if new_child
!= null then
8478 new_child
.parent
= self
8479 assert new_child
isa TKwinit
8480 _n_kwinit
= new_child
8486 for i
in [0.._n_args
.length
[ do
8487 if _n_args
[i
] == old_child
then
8488 if new_child
!= null then
8489 assert new_child
isa PExpr
8490 _n_args
[i
] = new_child
8491 new_child
.parent
= self
8493 _n_args
.remove_at
(i
)
8500 redef meth visit_all
(v
: Visitor)
8502 if _n_expr
!= null then
8505 if _n_kwinit
!= null then
8513 redef meth visit_all_reverse
(v
: Visitor)
8515 if _n_expr
!= null then
8518 if _n_kwinit
!= null then
8522 var i
= _n_args
.length
8530 redef class ABraExpr
8531 redef meth n_expr
=(n
: PExpr)
8539 private init empty_init
do end
8541 init init_abraexpr
(
8543 n_args
: Array[Object] # Should be Array[PExpr]
8547 if n_expr
!= null then
8548 n_expr
.parent
= self
8550 _n_args
= new List[PExpr]
8558 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
8560 assert old_child
!= null
8561 if _n_expr
== old_child
then
8562 if new_child
!= null then
8563 new_child
.parent
= self
8564 assert new_child
isa PExpr
8571 for i
in [0.._n_args
.length
[ do
8572 if _n_args
[i
] == old_child
then
8573 if new_child
!= null then
8574 assert new_child
isa PExpr
8575 _n_args
[i
] = new_child
8576 new_child
.parent
= self
8578 _n_args
.remove_at
(i
)
8585 redef meth visit_all
(v
: Visitor)
8587 if _n_expr
!= null then
8595 redef meth visit_all_reverse
(v
: Visitor)
8597 if _n_expr
!= null then
8601 var i
= _n_args
.length
8609 redef class ABraAssignExpr
8610 redef meth n_expr
=(n
: PExpr)
8617 redef meth n_assign
=(n
: TAssign)
8624 redef meth n_value
=(n
: PExpr)
8632 private init empty_init
do end
8634 init init_abraassignexpr
(
8636 n_args
: Array[Object] , # Should be Array[PExpr]
8642 if n_expr
!= null then
8643 n_expr
.parent
= self
8645 _n_args
= new List[PExpr]
8651 _n_assign
= n_assign
8652 if n_assign
!= null then
8653 n_assign
.parent
= self
8656 if n_value
!= null then
8657 n_value
.parent
= self
8661 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
8663 assert old_child
!= null
8664 if _n_expr
== old_child
then
8665 if new_child
!= null then
8666 new_child
.parent
= self
8667 assert new_child
isa PExpr
8674 for i
in [0.._n_args
.length
[ do
8675 if _n_args
[i
] == old_child
then
8676 if new_child
!= null then
8677 assert new_child
isa PExpr
8678 _n_args
[i
] = new_child
8679 new_child
.parent
= self
8681 _n_args
.remove_at
(i
)
8686 if _n_assign
== old_child
then
8687 if new_child
!= null then
8688 new_child
.parent
= self
8689 assert new_child
isa TAssign
8690 _n_assign
= new_child
8696 if _n_value
== old_child
then
8697 if new_child
!= null then
8698 new_child
.parent
= self
8699 assert new_child
isa PExpr
8700 _n_value
= new_child
8708 redef meth visit_all
(v
: Visitor)
8710 if _n_expr
!= null then
8716 if _n_assign
!= null then
8719 if _n_value
!= null then
8724 redef meth visit_all_reverse
(v
: Visitor)
8726 if _n_expr
!= null then
8730 var i
= _n_args
.length
8736 if _n_assign
!= null then
8739 if _n_value
!= null then
8744 redef class ABraReassignExpr
8745 redef meth n_expr
=(n
: PExpr)
8752 redef meth n_assign_op
=(n
: PAssignOp)
8759 redef meth n_value
=(n
: PExpr)
8767 private init empty_init
do end
8769 init init_abrareassignexpr
(
8771 n_args
: Array[Object] , # Should be Array[PExpr]
8772 n_assign_op
: PAssignOp ,
8777 if n_expr
!= null then
8778 n_expr
.parent
= self
8780 _n_args
= new List[PExpr]
8786 _n_assign_op
= n_assign_op
8787 if n_assign_op
!= null then
8788 n_assign_op
.parent
= self
8791 if n_value
!= null then
8792 n_value
.parent
= self
8796 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
8798 assert old_child
!= null
8799 if _n_expr
== old_child
then
8800 if new_child
!= null then
8801 new_child
.parent
= self
8802 assert new_child
isa PExpr
8809 for i
in [0.._n_args
.length
[ do
8810 if _n_args
[i
] == old_child
then
8811 if new_child
!= null then
8812 assert new_child
isa PExpr
8813 _n_args
[i
] = new_child
8814 new_child
.parent
= self
8816 _n_args
.remove_at
(i
)
8821 if _n_assign_op
== old_child
then
8822 if new_child
!= null then
8823 new_child
.parent
= self
8824 assert new_child
isa PAssignOp
8825 _n_assign_op
= new_child
8831 if _n_value
== old_child
then
8832 if new_child
!= null then
8833 new_child
.parent
= self
8834 assert new_child
isa PExpr
8835 _n_value
= new_child
8843 redef meth visit_all
(v
: Visitor)
8845 if _n_expr
!= null then
8851 if _n_assign_op
!= null then
8852 v
.visit
(_n_assign_op
)
8854 if _n_value
!= null then
8859 redef meth visit_all_reverse
(v
: Visitor)
8861 if _n_expr
!= null then
8865 var i
= _n_args
.length
8871 if _n_assign_op
!= null then
8872 v
.visit
(_n_assign_op
)
8874 if _n_value
!= null then
8879 redef class AVarExpr
8880 redef meth n_id
=(n
: TId)
8888 private init empty_init
do end
8890 init init_avarexpr
(
8895 if n_id
!= null then
8900 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
8902 assert old_child
!= null
8903 if _n_id
== old_child
then
8904 if new_child
!= null then
8905 new_child
.parent
= self
8906 assert new_child
isa TId
8915 redef meth visit_all
(v
: Visitor)
8917 if _n_id
!= null then
8922 redef meth visit_all_reverse
(v
: Visitor)
8924 if _n_id
!= null then
8929 redef class AVarAssignExpr
8930 redef meth n_id
=(n
: TId)
8937 redef meth n_assign
=(n
: TAssign)
8944 redef meth n_value
=(n
: PExpr)
8952 private init empty_init
do end
8954 init init_avarassignexpr
(
8961 if n_id
!= null then
8964 _n_assign
= n_assign
8965 if n_assign
!= null then
8966 n_assign
.parent
= self
8969 if n_value
!= null then
8970 n_value
.parent
= self
8974 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
8976 assert old_child
!= null
8977 if _n_id
== old_child
then
8978 if new_child
!= null then
8979 new_child
.parent
= self
8980 assert new_child
isa TId
8987 if _n_assign
== old_child
then
8988 if new_child
!= null then
8989 new_child
.parent
= self
8990 assert new_child
isa TAssign
8991 _n_assign
= new_child
8997 if _n_value
== old_child
then
8998 if new_child
!= null then
8999 new_child
.parent
= self
9000 assert new_child
isa PExpr
9001 _n_value
= new_child
9009 redef meth visit_all
(v
: Visitor)
9011 if _n_id
!= null then
9014 if _n_assign
!= null then
9017 if _n_value
!= null then
9022 redef meth visit_all_reverse
(v
: Visitor)
9024 if _n_id
!= null then
9027 if _n_assign
!= null then
9030 if _n_value
!= null then
9035 redef class AVarReassignExpr
9036 redef meth n_id
=(n
: TId)
9043 redef meth n_assign_op
=(n
: PAssignOp)
9050 redef meth n_value
=(n
: PExpr)
9058 private init empty_init
do end
9060 init init_avarreassignexpr
(
9062 n_assign_op
: PAssignOp ,
9067 if n_id
!= null then
9070 _n_assign_op
= n_assign_op
9071 if n_assign_op
!= null then
9072 n_assign_op
.parent
= self
9075 if n_value
!= null then
9076 n_value
.parent
= self
9080 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9082 assert old_child
!= null
9083 if _n_id
== old_child
then
9084 if new_child
!= null then
9085 new_child
.parent
= self
9086 assert new_child
isa TId
9093 if _n_assign_op
== old_child
then
9094 if new_child
!= null then
9095 new_child
.parent
= self
9096 assert new_child
isa PAssignOp
9097 _n_assign_op
= new_child
9103 if _n_value
== old_child
then
9104 if new_child
!= null then
9105 new_child
.parent
= self
9106 assert new_child
isa PExpr
9107 _n_value
= new_child
9115 redef meth visit_all
(v
: Visitor)
9117 if _n_id
!= null then
9120 if _n_assign_op
!= null then
9121 v
.visit
(_n_assign_op
)
9123 if _n_value
!= null then
9128 redef meth visit_all_reverse
(v
: Visitor)
9130 if _n_id
!= null then
9133 if _n_assign_op
!= null then
9134 v
.visit
(_n_assign_op
)
9136 if _n_value
!= null then
9141 redef class ARangeExpr
9142 redef meth n_expr
=(n
: PExpr)
9149 redef meth n_expr2
=(n
: PExpr)
9157 private init empty_init
do end
9159 init init_arangeexpr
(
9165 if n_expr
!= null then
9166 n_expr
.parent
= self
9169 if n_expr2
!= null then
9170 n_expr2
.parent
= self
9174 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9176 assert old_child
!= null
9177 if _n_expr
== old_child
then
9178 if new_child
!= null then
9179 new_child
.parent
= self
9180 assert new_child
isa PExpr
9187 if _n_expr2
== old_child
then
9188 if new_child
!= null then
9189 new_child
.parent
= self
9190 assert new_child
isa PExpr
9191 _n_expr2
= new_child
9199 redef meth visit_all
(v
: Visitor)
9201 if _n_expr
!= null then
9204 if _n_expr2
!= null then
9209 redef meth visit_all_reverse
(v
: Visitor)
9211 if _n_expr
!= null then
9214 if _n_expr2
!= null then
9219 redef class ACrangeExpr
9220 redef meth n_expr
=(n
: PExpr)
9227 redef meth n_expr2
=(n
: PExpr)
9235 private init empty_init
do end
9237 init init_acrangeexpr
(
9243 if n_expr
!= null then
9244 n_expr
.parent
= self
9247 if n_expr2
!= null then
9248 n_expr2
.parent
= self
9252 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9254 assert old_child
!= null
9255 if _n_expr
== old_child
then
9256 if new_child
!= null then
9257 new_child
.parent
= self
9258 assert new_child
isa PExpr
9265 if _n_expr2
== old_child
then
9266 if new_child
!= null then
9267 new_child
.parent
= self
9268 assert new_child
isa PExpr
9269 _n_expr2
= new_child
9277 redef meth visit_all
(v
: Visitor)
9279 if _n_expr
!= null then
9282 if _n_expr2
!= null then
9287 redef meth visit_all_reverse
(v
: Visitor)
9289 if _n_expr
!= null then
9292 if _n_expr2
!= null then
9297 redef class AOrangeExpr
9298 redef meth n_expr
=(n
: PExpr)
9305 redef meth n_expr2
=(n
: PExpr)
9313 private init empty_init
do end
9315 init init_aorangeexpr
(
9321 if n_expr
!= null then
9322 n_expr
.parent
= self
9325 if n_expr2
!= null then
9326 n_expr2
.parent
= self
9330 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9332 assert old_child
!= null
9333 if _n_expr
== old_child
then
9334 if new_child
!= null then
9335 new_child
.parent
= self
9336 assert new_child
isa PExpr
9343 if _n_expr2
== old_child
then
9344 if new_child
!= null then
9345 new_child
.parent
= self
9346 assert new_child
isa PExpr
9347 _n_expr2
= new_child
9355 redef meth visit_all
(v
: Visitor)
9357 if _n_expr
!= null then
9360 if _n_expr2
!= null then
9365 redef meth visit_all_reverse
(v
: Visitor)
9367 if _n_expr
!= null then
9370 if _n_expr2
!= null then
9375 redef class AArrayExpr
9377 private init empty_init
do end
9379 init init_aarrayexpr
(
9380 n_exprs
: Array[Object] # Should be Array[PExpr]
9383 _n_exprs
= new List[PExpr]
9391 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9393 assert old_child
!= null
9394 for i
in [0.._n_exprs
.length
[ do
9395 if _n_exprs
[i
] == old_child
then
9396 if new_child
!= null then
9397 assert new_child
isa PExpr
9398 _n_exprs
[i
] = new_child
9399 new_child
.parent
= self
9401 _n_exprs
.remove_at
(i
)
9408 redef meth visit_all
(v
: Visitor)
9410 for n
in _n_exprs
do
9415 redef meth visit_all_reverse
(v
: Visitor)
9418 var i
= _n_exprs
.length
9420 v
.visit
(_n_exprs
[i
])
9426 redef class ASelfExpr
9427 redef meth n_kwself
=(n
: TKwself)
9435 private init empty_init
do end
9437 init init_aselfexpr
(
9441 _n_kwself
= n_kwself
9442 if n_kwself
!= null then
9443 n_kwself
.parent
= self
9447 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9449 assert old_child
!= null
9450 if _n_kwself
== old_child
then
9451 if new_child
!= null then
9452 new_child
.parent
= self
9453 assert new_child
isa TKwself
9454 _n_kwself
= new_child
9462 redef meth visit_all
(v
: Visitor)
9464 if _n_kwself
!= null then
9469 redef meth visit_all_reverse
(v
: Visitor)
9471 if _n_kwself
!= null then
9476 redef class AImplicitSelfExpr
9478 private init empty_init
do end
9480 init init_aimplicitselfexpr
9484 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9486 assert old_child
!= null
9489 redef meth visit_all
(v
: Visitor)
9493 redef meth visit_all_reverse
(v
: Visitor)
9497 redef class ATrueExpr
9498 redef meth n_kwtrue
=(n
: TKwtrue)
9506 private init empty_init
do end
9508 init init_atrueexpr
(
9512 _n_kwtrue
= n_kwtrue
9513 if n_kwtrue
!= null then
9514 n_kwtrue
.parent
= self
9518 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9520 assert old_child
!= null
9521 if _n_kwtrue
== old_child
then
9522 if new_child
!= null then
9523 new_child
.parent
= self
9524 assert new_child
isa TKwtrue
9525 _n_kwtrue
= new_child
9533 redef meth visit_all
(v
: Visitor)
9535 if _n_kwtrue
!= null then
9540 redef meth visit_all_reverse
(v
: Visitor)
9542 if _n_kwtrue
!= null then
9547 redef class AFalseExpr
9548 redef meth n_kwfalse
=(n
: TKwfalse)
9556 private init empty_init
do end
9558 init init_afalseexpr
(
9562 _n_kwfalse
= n_kwfalse
9563 if n_kwfalse
!= null then
9564 n_kwfalse
.parent
= self
9568 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9570 assert old_child
!= null
9571 if _n_kwfalse
== old_child
then
9572 if new_child
!= null then
9573 new_child
.parent
= self
9574 assert new_child
isa TKwfalse
9575 _n_kwfalse
= new_child
9583 redef meth visit_all
(v
: Visitor)
9585 if _n_kwfalse
!= null then
9590 redef meth visit_all_reverse
(v
: Visitor)
9592 if _n_kwfalse
!= null then
9597 redef class ANullExpr
9598 redef meth n_kwnull
=(n
: TKwnull)
9606 private init empty_init
do end
9608 init init_anullexpr
(
9612 _n_kwnull
= n_kwnull
9613 if n_kwnull
!= null then
9614 n_kwnull
.parent
= self
9618 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9620 assert old_child
!= null
9621 if _n_kwnull
== old_child
then
9622 if new_child
!= null then
9623 new_child
.parent
= self
9624 assert new_child
isa TKwnull
9625 _n_kwnull
= new_child
9633 redef meth visit_all
(v
: Visitor)
9635 if _n_kwnull
!= null then
9640 redef meth visit_all_reverse
(v
: Visitor)
9642 if _n_kwnull
!= null then
9647 redef class AIntExpr
9648 redef meth n_number
=(n
: TNumber)
9656 private init empty_init
do end
9658 init init_aintexpr
(
9662 _n_number
= n_number
9663 if n_number
!= null then
9664 n_number
.parent
= self
9668 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9670 assert old_child
!= null
9671 if _n_number
== old_child
then
9672 if new_child
!= null then
9673 new_child
.parent
= self
9674 assert new_child
isa TNumber
9675 _n_number
= new_child
9683 redef meth visit_all
(v
: Visitor)
9685 if _n_number
!= null then
9690 redef meth visit_all_reverse
(v
: Visitor)
9692 if _n_number
!= null then
9697 redef class AFloatExpr
9698 redef meth n_float
=(n
: TFloat)
9706 private init empty_init
do end
9708 init init_afloatexpr
(
9713 if n_float
!= null then
9714 n_float
.parent
= self
9718 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9720 assert old_child
!= null
9721 if _n_float
== old_child
then
9722 if new_child
!= null then
9723 new_child
.parent
= self
9724 assert new_child
isa TFloat
9725 _n_float
= new_child
9733 redef meth visit_all
(v
: Visitor)
9735 if _n_float
!= null then
9740 redef meth visit_all_reverse
(v
: Visitor)
9742 if _n_float
!= null then
9747 redef class ACharExpr
9748 redef meth n_char
=(n
: TChar)
9756 private init empty_init
do end
9758 init init_acharexpr
(
9763 if n_char
!= null then
9764 n_char
.parent
= self
9768 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9770 assert old_child
!= null
9771 if _n_char
== old_child
then
9772 if new_child
!= null then
9773 new_child
.parent
= self
9774 assert new_child
isa TChar
9783 redef meth visit_all
(v
: Visitor)
9785 if _n_char
!= null then
9790 redef meth visit_all_reverse
(v
: Visitor)
9792 if _n_char
!= null then
9797 redef class AStringExpr
9798 redef meth n_string
=(n
: TString)
9806 private init empty_init
do end
9808 init init_astringexpr
(
9812 _n_string
= n_string
9813 if n_string
!= null then
9814 n_string
.parent
= self
9818 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9820 assert old_child
!= null
9821 if _n_string
== old_child
then
9822 if new_child
!= null then
9823 new_child
.parent
= self
9824 assert new_child
isa TString
9825 _n_string
= new_child
9833 redef meth visit_all
(v
: Visitor)
9835 if _n_string
!= null then
9840 redef meth visit_all_reverse
(v
: Visitor)
9842 if _n_string
!= null then
9847 redef class AStartStringExpr
9848 redef meth n_string
=(n
: TStartString)
9856 private init empty_init
do end
9858 init init_astartstringexpr
(
9859 n_string
: TStartString
9862 _n_string
= n_string
9863 if n_string
!= null then
9864 n_string
.parent
= self
9868 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9870 assert old_child
!= null
9871 if _n_string
== old_child
then
9872 if new_child
!= null then
9873 new_child
.parent
= self
9874 assert new_child
isa TStartString
9875 _n_string
= new_child
9883 redef meth visit_all
(v
: Visitor)
9885 if _n_string
!= null then
9890 redef meth visit_all_reverse
(v
: Visitor)
9892 if _n_string
!= null then
9897 redef class AMidStringExpr
9898 redef meth n_string
=(n
: TMidString)
9906 private init empty_init
do end
9908 init init_amidstringexpr
(
9909 n_string
: TMidString
9912 _n_string
= n_string
9913 if n_string
!= null then
9914 n_string
.parent
= self
9918 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9920 assert old_child
!= null
9921 if _n_string
== old_child
then
9922 if new_child
!= null then
9923 new_child
.parent
= self
9924 assert new_child
isa TMidString
9925 _n_string
= new_child
9933 redef meth visit_all
(v
: Visitor)
9935 if _n_string
!= null then
9940 redef meth visit_all_reverse
(v
: Visitor)
9942 if _n_string
!= null then
9947 redef class AEndStringExpr
9948 redef meth n_string
=(n
: TEndString)
9956 private init empty_init
do end
9958 init init_aendstringexpr
(
9959 n_string
: TEndString
9962 _n_string
= n_string
9963 if n_string
!= null then
9964 n_string
.parent
= self
9968 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
9970 assert old_child
!= null
9971 if _n_string
== old_child
then
9972 if new_child
!= null then
9973 new_child
.parent
= self
9974 assert new_child
isa TEndString
9975 _n_string
= new_child
9983 redef meth visit_all
(v
: Visitor)
9985 if _n_string
!= null then
9990 redef meth visit_all_reverse
(v
: Visitor)
9992 if _n_string
!= null then
9997 redef class ASuperstringExpr
9999 private init empty_init
do end
10001 init init_asuperstringexpr
(
10002 n_exprs
: Array[Object] # Should be Array[PExpr]
10005 _n_exprs
= new List[PExpr]
10006 for n
in n_exprs
do
10013 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
10015 assert old_child
!= null
10016 for i
in [0.._n_exprs
.length
[ do
10017 if _n_exprs
[i
] == old_child
then
10018 if new_child
!= null then
10019 assert new_child
isa PExpr
10020 _n_exprs
[i
] = new_child
10021 new_child
.parent
= self
10023 _n_exprs
.remove_at
(i
)
10030 redef meth visit_all
(v
: Visitor)
10032 for n
in _n_exprs
do
10037 redef meth visit_all_reverse
(v
: Visitor)
10040 var i
= _n_exprs
.length
10042 v
.visit
(_n_exprs
[i
])
10048 redef class AParExpr
10049 redef meth n_expr
=(n
: PExpr)
10057 private init empty_init
do end
10059 init init_aparexpr
(
10064 if n_expr
!= null then
10065 n_expr
.parent
= self
10069 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
10071 assert old_child
!= null
10072 if _n_expr
== old_child
then
10073 if new_child
!= null then
10074 new_child
.parent
= self
10075 assert new_child
isa PExpr
10076 _n_expr
= new_child
10084 redef meth visit_all
(v
: Visitor)
10086 if _n_expr
!= null then
10091 redef meth visit_all_reverse
(v
: Visitor)
10093 if _n_expr
!= null then
10098 redef class APlusAssignOp
10099 redef meth n_pluseq
=(n
: TPluseq)
10107 private init empty_init
do end
10109 init init_aplusassignop
(
10113 _n_pluseq
= n_pluseq
10114 if n_pluseq
!= null then
10115 n_pluseq
.parent
= self
10119 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
10121 assert old_child
!= null
10122 if _n_pluseq
== old_child
then
10123 if new_child
!= null then
10124 new_child
.parent
= self
10125 assert new_child
isa TPluseq
10126 _n_pluseq
= new_child
10134 redef meth visit_all
(v
: Visitor)
10136 if _n_pluseq
!= null then
10141 redef meth visit_all_reverse
(v
: Visitor)
10143 if _n_pluseq
!= null then
10148 redef class AMinusAssignOp
10149 redef meth n_minuseq
=(n
: TMinuseq)
10157 private init empty_init
do end
10159 init init_aminusassignop
(
10160 n_minuseq
: TMinuseq
10163 _n_minuseq
= n_minuseq
10164 if n_minuseq
!= null then
10165 n_minuseq
.parent
= self
10169 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
10171 assert old_child
!= null
10172 if _n_minuseq
== old_child
then
10173 if new_child
!= null then
10174 new_child
.parent
= self
10175 assert new_child
isa TMinuseq
10176 _n_minuseq
= new_child
10184 redef meth visit_all
(v
: Visitor)
10186 if _n_minuseq
!= null then
10187 v
.visit
(_n_minuseq
)
10191 redef meth visit_all_reverse
(v
: Visitor)
10193 if _n_minuseq
!= null then
10194 v
.visit
(_n_minuseq
)
10198 redef class AQualified
10199 redef meth n_classid
=(n
: TClassid)
10207 private init empty_init
do end
10209 init init_aqualified
(
10210 n_id
: Array[Object] , # Should be Array[TId]
10211 n_classid
: TClassid
10214 _n_id
= new List[TId]
10220 _n_classid
= n_classid
10221 if n_classid
!= null then
10222 n_classid
.parent
= self
10226 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
10228 assert old_child
!= null
10229 for i
in [0.._n_id
.length
[ do
10230 if _n_id
[i
] == old_child
then
10231 if new_child
!= null then
10232 assert new_child
isa TId
10233 _n_id
[i
] = new_child
10234 new_child
.parent
= self
10241 if _n_classid
== old_child
then
10242 if new_child
!= null then
10243 new_child
.parent
= self
10244 assert new_child
isa TClassid
10245 _n_classid
= new_child
10253 redef meth visit_all
(v
: Visitor)
10258 if _n_classid
!= null then
10259 v
.visit
(_n_classid
)
10263 redef meth visit_all_reverse
(v
: Visitor)
10266 var i
= _n_id
.length
10272 if _n_classid
!= null then
10273 v
.visit
(_n_classid
)
10279 private init empty_init
do end
10282 n_comment
: Array[Object] # Should be Array[TComment]
10285 _n_comment
= new List[TComment]
10286 for n
in n_comment
do
10287 assert n
isa TComment
10293 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
10295 assert old_child
!= null
10296 for i
in [0.._n_comment
.length
[ do
10297 if _n_comment
[i
] == old_child
then
10298 if new_child
!= null then
10299 assert new_child
isa TComment
10300 _n_comment
[i
] = new_child
10301 new_child
.parent
= self
10303 _n_comment
.remove_at
(i
)
10310 redef meth visit_all
(v
: Visitor)
10312 for n
in _n_comment
do
10317 redef meth visit_all_reverse
(v
: Visitor)
10320 var i
= _n_comment
.length
10322 v
.visit
(_n_comment
[i
])
10338 redef meth replace_child
(old_child
: PNode, new_child
: PNode)
10340 assert old_child
!= null
10341 if _n_base
== old_child
then
10342 if new_child
== null then
10344 new_child
.parent
= self
10345 assert new_child
isa PModule
10346 _n_base
= new_child
10348 old_child
.parent
= null
10353 redef meth visit_all
(v
: Visitor)
10355 if _n_base
!= null then
10360 redef meth visit_all_reverse
(v
: Visitor)
10362 if _n_base
!= null then