001    /* This file was generated with JastAdd2 (http://jastadd.org) version 2.1.13-12-g880e696 */
002    package org.extendj.ast;
003    
004    import java.util.HashSet;
005    import java.io.File;
006    import java.util.Set;
007    import java.util.Collections;
008    import java.util.Collection;
009    import java.util.ArrayList;
010    import beaver.*;
011    import java.util.*;
012    import java.io.ByteArrayOutputStream;
013    import java.io.PrintStream;
014    import java.lang.reflect.InvocationTargetException;
015    import java.lang.reflect.Method;
016    import org.jastadd.util.*;
017    import java.util.zip.*;
018    import java.io.*;
019    import org.jastadd.util.PrettyPrintable;
020    import org.jastadd.util.PrettyPrinter;
021    import java.io.FileNotFoundException;
022    import java.io.BufferedInputStream;
023    import java.io.DataInputStream;
024    /**
025     * @ast node
026     * @declaredat /home/jesper/git/extendj/java4/grammar/Java.ast:59
027     * @production FloatType : {@link FloatingPointType};
028    
029     */
030    public class FloatType extends FloatingPointType implements Cloneable {
031      /**
032       * @aspect Java4PrettyPrint
033       * @declaredat /home/jesper/git/extendj/java4/frontend/PrettyPrint.jadd:359
034       */
035      public void prettyPrint(PrettyPrinter out) {
036        out.print("float");
037      }
038      /**
039       * @aspect Attributes
040       * @declaredat /home/jesper/git/extendj/java4/backend/Attributes.jrag:89
041       */
042      public int addConstant(ConstantPool p, Constant c)    { return p.addConstant(c.floatValue()); }
043      /**
044       * @aspect CodeGeneration
045       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:173
046       */
047      public void emitPushConstant(CodeGeneration gen, int value) { FloatingPointLiteral.push(gen, value); }
048      /**
049       * @aspect CodeGeneration
050       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:244
051       */
052      public void emitReturn(CodeGeneration gen)     { gen.emit(Bytecode.FRETURN);}
053      /**
054       * @aspect CodeGeneration
055       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:295
056       */
057      public void emitLoadLocal(CodeGeneration gen, int pos) {
058        gen.maxLocals = Math.max(gen.maxLocals, pos+1);
059        if (pos == 0) {
060          gen.emit(Bytecode.FLOAD_0);
061        } else if (pos == 1) {
062          gen.emit(Bytecode.FLOAD_1);
063        } else if (pos == 2) {
064          gen.emit(Bytecode.FLOAD_2);
065        } else if (pos == 3) {
066          gen.emit(Bytecode.FLOAD_3);
067        } else if (pos < 256) {
068          gen.emit(Bytecode.FLOAD).add(pos);
069        } else {
070          gen.emit(Bytecode.WIDE).emit(Bytecode.FLOAD).add2(pos);
071        }
072      }
073      /**
074       * @aspect CodeGeneration
075       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:438
076       */
077      public void emitStoreLocal(CodeGeneration gen, int pos) {
078        gen.maxLocals = Math.max(gen.maxLocals, pos+1);
079        if (pos == 0) {
080          gen.emit(Bytecode.FSTORE_0);
081        } else if (pos == 1) {
082          gen.emit(Bytecode.FSTORE_1);
083        } else if (pos == 2) {
084          gen.emit(Bytecode.FSTORE_2);
085        } else if (pos == 3) {
086          gen.emit(Bytecode.FSTORE_3);
087        } else if (pos < 256) {
088          gen.emit(Bytecode.FSTORE).add(pos);
089        } else {
090          gen.emit(Bytecode.WIDE).emit(Bytecode.FSTORE).add2(pos);
091        }
092      }
093      /**
094       * @aspect CodeGenerationConversions
095       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:582
096       */
097      void emitCastTo(CodeGeneration gen, TypeDecl type)    { type.floatToThis(gen); }
098      /**
099       * @aspect CodeGenerationConversions
100       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:594
101       */
102      void intToThis(CodeGeneration gen)  { gen.emit(Bytecode.I2F); }
103      /**
104       * @aspect CodeGenerationConversions
105       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:605
106       */
107      void floatToThis(CodeGeneration gen)  { }
108      /**
109       * @aspect CodeGenerationConversions
110       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:614
111       */
112      void doubleToThis(CodeGeneration gen)  { gen.emit(Bytecode.D2F); }
113      /**
114       * @aspect CodeGenerationConversions
115       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:623
116       */
117      void longToThis(CodeGeneration gen)  { gen.emit(Bytecode.L2F); }
118      /**
119       * @aspect CodeGenerationConversions
120       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:630
121       */
122      void byteToThis(CodeGeneration gen)    { gen.emit(Bytecode.I2F); }
123      /**
124       * @aspect CodeGenerationConversions
125       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:638
126       */
127      void charToThis(CodeGeneration gen)    { gen.emit(Bytecode.I2F); }
128      /**
129       * @aspect CodeGenerationConversions
130       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:646
131       */
132      void shortToThis(CodeGeneration gen)    { gen.emit(Bytecode.I2F); }
133      /**
134       * @aspect CodeGenerationBinaryOperations
135       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:678
136       */
137      void neg(CodeGeneration gen)    { gen.emit(Bytecode.FNEG); }
138      /**
139       * @aspect CodeGenerationBinaryOperations
140       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:690
141       */
142      void add(CodeGeneration gen) {gen.emit(Bytecode.FADD);}
143      /**
144       * @aspect CodeGenerationBinaryOperations
145       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:696
146       */
147      void sub(CodeGeneration gen) {gen.emit(Bytecode.FSUB);}
148      /**
149       * @aspect CodeGenerationBinaryOperations
150       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:702
151       */
152      void mul(CodeGeneration gen) {gen.emit(Bytecode.FMUL);}
153      /**
154       * @aspect CodeGenerationBinaryOperations
155       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:708
156       */
157      void div(CodeGeneration gen) {gen.emit(Bytecode.FDIV);}
158      /**
159       * @aspect CodeGenerationBinaryOperations
160       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:714
161       */
162      void rem(CodeGeneration gen) {gen.emit(Bytecode.FREM);}
163      /**
164       * @aspect CodeGenerationBranch
165       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:749
166       */
167      public void branchLT(CodeGeneration gen, int label)    { gen.emit(Bytecode.FCMPG).emitCompare(Bytecode.IFLT, label); }
168      /**
169       * @aspect CodeGenerationBranch
170       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:755
171       */
172      public void branchLTInv(CodeGeneration gen, int label)  { gen.emit(Bytecode.FCMPL).emitCompare(Bytecode.IFLT, label); }
173      /**
174       * @aspect CodeGenerationBranch
175       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:759
176       */
177      public void branchLE(CodeGeneration gen, int label)    { gen.emit(Bytecode.FCMPG).emitCompare(Bytecode.IFLE, label); }
178      /**
179       * @aspect CodeGenerationBranch
180       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:765
181       */
182      public void branchLEInv(CodeGeneration gen, int label)  { gen.emit(Bytecode.FCMPL).emitCompare(Bytecode.IFLE, label); }
183      /**
184       * @aspect CodeGenerationBranch
185       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:769
186       */
187      public void branchGE(CodeGeneration gen, int label)    { gen.emit(Bytecode.FCMPL).emitCompare(Bytecode.IFGE, label); }
188      /**
189       * @aspect CodeGenerationBranch
190       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:775
191       */
192      public void branchGEInv(CodeGeneration gen, int label)  { gen.emit(Bytecode.FCMPG).emitCompare(Bytecode.IFGE, label); }
193      /**
194       * @aspect CodeGenerationBranch
195       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:779
196       */
197      public void branchGT(CodeGeneration gen, int label)    { gen.emit(Bytecode.FCMPL).emitCompare(Bytecode.IFGT, label); }
198      /**
199       * @aspect CodeGenerationBranch
200       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:785
201       */
202      public void branchGTInv(CodeGeneration gen, int label)  { gen.emit(Bytecode.FCMPG).emitCompare(Bytecode.IFGT, label); }
203      /**
204       * @aspect CodeGenerationBranch
205       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:789
206       */
207      public void branchEQ(CodeGeneration gen, int label)     { gen.emit(Bytecode.FCMPL).emitCompare(Bytecode.IFEQ, label); }
208      /**
209       * @aspect CodeGenerationBranch
210       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:798
211       */
212      public void branchNE(CodeGeneration gen, int label)     { gen.emit(Bytecode.FCMPL).emitCompare(Bytecode.IFNE, label); }
213      /**
214       * @aspect AnnotationsCodegen
215       * @declaredat /home/jesper/git/extendj/java5/backend/AnnotationsCodegen.jrag:223
216       */
217      public int addAnnotConstant(ConstantPool p, Constant c) {
218        return addConstant(p, c);
219      }
220      /**
221       * @declaredat ASTNode:1
222       */
223      public FloatType() {
224        super();
225      }
226      /**
227       * Initializes the child array to the correct size.
228       * Initializes List and Opt nta children.
229       * @apilevel internal
230       * @ast method
231       * @declaredat ASTNode:10
232       */
233      public void init$Children() {
234        children = new ASTNode[3];
235        setChild(new Opt(), 1);
236        setChild(new List(), 2);
237      }
238      /**
239       * @declaredat ASTNode:15
240       */
241      public FloatType(Modifiers p0, String p1, Opt<Access> p2, List<BodyDecl> p3) {
242        setChild(p0, 0);
243        setID(p1);
244        setChild(p2, 1);
245        setChild(p3, 2);
246      }
247      /**
248       * @declaredat ASTNode:21
249       */
250      public FloatType(Modifiers p0, beaver.Symbol p1, Opt<Access> p2, List<BodyDecl> p3) {
251        setChild(p0, 0);
252        setID(p1);
253        setChild(p2, 1);
254        setChild(p3, 2);
255      }
256      /**
257       * @apilevel low-level
258       * @declaredat ASTNode:30
259       */
260      protected int numChildren() {
261        return 3;
262      }
263      /**
264       * @apilevel internal
265       * @declaredat ASTNode:36
266       */
267      public boolean mayHaveRewrite() {
268        return false;
269      }
270      /**
271       * @apilevel internal
272       * @declaredat ASTNode:42
273       */
274      public void flushAttrCache() {
275        super.flushAttrCache();
276        typeDescriptor_reset();
277        jvmName_reset();
278        boxed_reset();
279      }
280      /**
281       * @apilevel internal
282       * @declaredat ASTNode:51
283       */
284      public void flushCollectionCache() {
285        super.flushCollectionCache();
286      }
287      /**
288       * @apilevel internal
289       * @declaredat ASTNode:57
290       */
291      public void flushRewriteCache() {
292        super.flushRewriteCache();
293      }
294      /**
295       * @apilevel internal
296       * @declaredat ASTNode:63
297       */
298      public FloatType clone() throws CloneNotSupportedException {
299        FloatType node = (FloatType) super.clone();
300        return node;
301      }
302      /**
303       * @apilevel internal
304       * @declaredat ASTNode:70
305       */
306      public FloatType copy() {
307        try {
308          FloatType node = (FloatType) clone();
309          node.parent = null;
310          if (children != null) {
311            node.children = (ASTNode[]) children.clone();
312          }
313          return node;
314        } catch (CloneNotSupportedException e) {
315          throw new Error("Error: clone not supported for " + getClass().getName());
316        }
317      }
318      /**
319       * Create a deep copy of the AST subtree at this node.
320       * The copy is dangling, i.e. has no parent.
321       * @return dangling copy of the subtree at this node
322       * @apilevel low-level
323       * @deprecated Please use treeCopy or treeCopyNoTransform instead
324       * @declaredat ASTNode:89
325       */
326      @Deprecated
327      public FloatType fullCopy() {
328        return treeCopyNoTransform();
329      }
330      /**
331       * Create a deep copy of the AST subtree at this node.
332       * The copy is dangling, i.e. has no parent.
333       * @return dangling copy of the subtree at this node
334       * @apilevel low-level
335       * @declaredat ASTNode:99
336       */
337      public FloatType treeCopyNoTransform() {
338        FloatType tree = (FloatType) copy();
339        if (children != null) {
340          for (int i = 0; i < children.length; ++i) {
341            ASTNode child = (ASTNode) children[i];
342            if (child != null) {
343              child = child.treeCopyNoTransform();
344              tree.setChild(child, i);
345            }
346          }
347        }
348        return tree;
349      }
350      /**
351       * Create a deep copy of the AST subtree at this node.
352       * The subtree of this node is traversed to trigger rewrites before copy.
353       * The copy is dangling, i.e. has no parent.
354       * @return dangling copy of the subtree at this node
355       * @apilevel low-level
356       * @declaredat ASTNode:119
357       */
358      public FloatType treeCopy() {
359        doFullTraversal();
360        return treeCopyNoTransform();
361      }
362      /**
363       * @apilevel internal
364       * @declaredat ASTNode:126
365       */
366      protected boolean is$Equal(ASTNode node) {
367        return super.is$Equal(node) && (tokenString_ID == ((FloatType)node).tokenString_ID);    
368      }
369      /**
370       * Replaces the Modifiers child.
371       * @param node The new node to replace the Modifiers child.
372       * @apilevel high-level
373       */
374      public void setModifiers(Modifiers node) {
375        setChild(node, 0);
376      }
377      /**
378       * Retrieves the Modifiers child.
379       * @return The current node used as the Modifiers child.
380       * @apilevel high-level
381       */
382      @ASTNodeAnnotation.Child(name="Modifiers")
383      public Modifiers getModifiers() {
384        return (Modifiers) getChild(0);
385      }
386      /**
387       * Retrieves the Modifiers child.
388       * <p><em>This method does not invoke AST transformations.</em></p>
389       * @return The current node used as the Modifiers child.
390       * @apilevel low-level
391       */
392      public Modifiers getModifiersNoTransform() {
393        return (Modifiers) getChildNoTransform(0);
394      }
395      /**
396       * Replaces the lexeme ID.
397       * @param value The new value for the lexeme ID.
398       * @apilevel high-level
399       */
400      public void setID(String value) {
401        tokenString_ID = value;
402      }
403      /**
404       * JastAdd-internal setter for lexeme ID using the Beaver parser.
405       * @param symbol Symbol containing the new value for the lexeme ID
406       * @apilevel internal
407       */
408      public void setID(beaver.Symbol symbol) {
409        if (symbol.value != null && !(symbol.value instanceof String))
410        throw new UnsupportedOperationException("setID is only valid for String lexemes");
411        tokenString_ID = (String)symbol.value;
412        IDstart = symbol.getStart();
413        IDend = symbol.getEnd();
414      }
415      /**
416       * Retrieves the value for the lexeme ID.
417       * @return The value for the lexeme ID.
418       * @apilevel high-level
419       */
420      @ASTNodeAnnotation.Token(name="ID")
421      public String getID() {
422        return tokenString_ID != null ? tokenString_ID : "";
423      }
424      /**
425       * Replaces the optional node for the SuperClass child. This is the <code>Opt</code>
426       * node containing the child SuperClass, not the actual child!
427       * @param opt The new node to be used as the optional node for the SuperClass child.
428       * @apilevel low-level
429       */
430      public void setSuperClassOpt(Opt<Access> opt) {
431        setChild(opt, 1);
432      }
433      /**
434       * Replaces the (optional) SuperClass child.
435       * @param node The new node to be used as the SuperClass child.
436       * @apilevel high-level
437       */
438      public void setSuperClass(Access node) {
439        getSuperClassOpt().setChild(node, 0);
440      }
441      /**
442       * Check whether the optional SuperClass child exists.
443       * @return {@code true} if the optional SuperClass child exists, {@code false} if it does not.
444       * @apilevel high-level
445       */
446      public boolean hasSuperClass() {
447        return getSuperClassOpt().getNumChild() != 0;
448      }
449      /**
450       * Retrieves the (optional) SuperClass child.
451       * @return The SuperClass child, if it exists. Returns {@code null} otherwise.
452       * @apilevel low-level
453       */
454      public Access getSuperClass() {
455        return (Access) getSuperClassOpt().getChild(0);
456      }
457      /**
458       * Retrieves the optional node for the SuperClass child. This is the <code>Opt</code> node containing the child SuperClass, not the actual child!
459       * @return The optional node for child the SuperClass child.
460       * @apilevel low-level
461       */
462      @ASTNodeAnnotation.OptChild(name="SuperClass")
463      public Opt<Access> getSuperClassOpt() {
464        return (Opt<Access>) getChild(1);
465      }
466      /**
467       * Retrieves the optional node for child SuperClass. This is the <code>Opt</code> node containing the child SuperClass, not the actual child!
468       * <p><em>This method does not invoke AST transformations.</em></p>
469       * @return The optional node for child SuperClass.
470       * @apilevel low-level
471       */
472      public Opt<Access> getSuperClassOptNoTransform() {
473        return (Opt<Access>) getChildNoTransform(1);
474      }
475      /**
476       * Replaces the BodyDecl list.
477       * @param list The new list node to be used as the BodyDecl list.
478       * @apilevel high-level
479       */
480      public void setBodyDeclList(List<BodyDecl> list) {
481        setChild(list, 2);
482      }
483      /**
484       * Retrieves the number of children in the BodyDecl list.
485       * @return Number of children in the BodyDecl list.
486       * @apilevel high-level
487       */
488      public int getNumBodyDecl() {
489        return getBodyDeclList().getNumChild();
490      }
491      /**
492       * Retrieves the number of children in the BodyDecl list.
493       * Calling this method will not trigger rewrites.
494       * @return Number of children in the BodyDecl list.
495       * @apilevel low-level
496       */
497      public int getNumBodyDeclNoTransform() {
498        return getBodyDeclListNoTransform().getNumChildNoTransform();
499      }
500      /**
501       * Retrieves the element at index {@code i} in the BodyDecl list.
502       * @param i Index of the element to return.
503       * @return The element at position {@code i} in the BodyDecl list.
504       * @apilevel high-level
505       */
506      public BodyDecl getBodyDecl(int i) {
507        return (BodyDecl) getBodyDeclList().getChild(i);
508      }
509      /**
510       * Check whether the BodyDecl list has any children.
511       * @return {@code true} if it has at least one child, {@code false} otherwise.
512       * @apilevel high-level
513       */
514      public boolean hasBodyDecl() {
515        return getBodyDeclList().getNumChild() != 0;
516      }
517      /**
518       * Append an element to the BodyDecl list.
519       * @param node The element to append to the BodyDecl list.
520       * @apilevel high-level
521       */
522      public void addBodyDecl(BodyDecl node) {
523        List<BodyDecl> list = (parent == null) ? getBodyDeclListNoTransform() : getBodyDeclList();
524        list.addChild(node);
525      }
526      /**
527       * @apilevel low-level
528       */
529      public void addBodyDeclNoTransform(BodyDecl node) {
530        List<BodyDecl> list = getBodyDeclListNoTransform();
531        list.addChild(node);
532      }
533      /**
534       * Replaces the BodyDecl list element at index {@code i} with the new node {@code node}.
535       * @param node The new node to replace the old list element.
536       * @param i The list index of the node to be replaced.
537       * @apilevel high-level
538       */
539      public void setBodyDecl(BodyDecl node, int i) {
540        List<BodyDecl> list = getBodyDeclList();
541        list.setChild(node, i);
542      }
543      /**
544       * Retrieves the BodyDecl list.
545       * @return The node representing the BodyDecl list.
546       * @apilevel high-level
547       */
548      @ASTNodeAnnotation.ListChild(name="BodyDecl")
549      public List<BodyDecl> getBodyDeclList() {
550        List<BodyDecl> list = (List<BodyDecl>) getChild(2);
551        return list;
552      }
553      /**
554       * Retrieves the BodyDecl list.
555       * <p><em>This method does not invoke AST transformations.</em></p>
556       * @return The node representing the BodyDecl list.
557       * @apilevel low-level
558       */
559      public List<BodyDecl> getBodyDeclListNoTransform() {
560        return (List<BodyDecl>) getChildNoTransform(2);
561      }
562      /**
563       * Retrieves the BodyDecl list.
564       * @return The node representing the BodyDecl list.
565       * @apilevel high-level
566       */
567      public List<BodyDecl> getBodyDecls() {
568        return getBodyDeclList();
569      }
570      /**
571       * Retrieves the BodyDecl list.
572       * <p><em>This method does not invoke AST transformations.</em></p>
573       * @return The node representing the BodyDecl list.
574       * @apilevel low-level
575       */
576      public List<BodyDecl> getBodyDeclsNoTransform() {
577        return getBodyDeclListNoTransform();
578      }
579      /**
580       * @attribute syn
581       * @aspect ConstantExpression
582       * @declaredat /home/jesper/git/extendj/java4/frontend/ConstantExpression.jrag:72
583       */
584      @ASTNodeAnnotation.Attribute
585      public Constant cast(Constant c) {
586        Constant cast_Constant_value = Constant.create(c.floatValue());
587    
588        return cast_Constant_value;
589      }
590      /**
591       * @attribute syn
592       * @aspect ConstantExpression
593       * @declaredat /home/jesper/git/extendj/java4/frontend/ConstantExpression.jrag:86
594       */
595      @ASTNodeAnnotation.Attribute
596      public Constant plus(Constant c) {
597        Constant plus_Constant_value = c;
598    
599        return plus_Constant_value;
600      }
601      /**
602       * @attribute syn
603       * @aspect ConstantExpression
604       * @declaredat /home/jesper/git/extendj/java4/frontend/ConstantExpression.jrag:95
605       */
606      @ASTNodeAnnotation.Attribute
607      public Constant minus(Constant c) {
608        Constant minus_Constant_value = Constant.create(-c.floatValue());
609    
610        return minus_Constant_value;
611      }
612      /**
613       * @attribute syn
614       * @aspect ConstantExpression
615       * @declaredat /home/jesper/git/extendj/java4/frontend/ConstantExpression.jrag:111
616       */
617      @ASTNodeAnnotation.Attribute
618      public Constant mul(Constant c1, Constant c2) {
619        Constant mul_Constant_Constant_value = Constant.create(c1.floatValue() * c2.floatValue());
620    
621        return mul_Constant_Constant_value;
622      }
623      /**
624       * @attribute syn
625       * @aspect ConstantExpression
626       * @declaredat /home/jesper/git/extendj/java4/frontend/ConstantExpression.jrag:120
627       */
628      @ASTNodeAnnotation.Attribute
629      public Constant div(Constant c1, Constant c2) {
630        Constant div_Constant_Constant_value = Constant.create(c1.floatValue() / c2.floatValue());
631    
632        return div_Constant_Constant_value;
633      }
634      /**
635       * @attribute syn
636       * @aspect ConstantExpression
637       * @declaredat /home/jesper/git/extendj/java4/frontend/ConstantExpression.jrag:129
638       */
639      @ASTNodeAnnotation.Attribute
640      public Constant mod(Constant c1, Constant c2) {
641        Constant mod_Constant_Constant_value = Constant.create(c1.floatValue() % c2.floatValue());
642    
643        return mod_Constant_Constant_value;
644      }
645      /**
646       * @attribute syn
647       * @aspect ConstantExpression
648       * @declaredat /home/jesper/git/extendj/java4/frontend/ConstantExpression.jrag:138
649       */
650      @ASTNodeAnnotation.Attribute
651      public Constant add(Constant c1, Constant c2) {
652        Constant add_Constant_Constant_value = Constant.create(c1.floatValue() + c2.floatValue());
653    
654        return add_Constant_Constant_value;
655      }
656      /**
657       * @attribute syn
658       * @aspect ConstantExpression
659       * @declaredat /home/jesper/git/extendj/java4/frontend/ConstantExpression.jrag:148
660       */
661      @ASTNodeAnnotation.Attribute
662      public Constant sub(Constant c1, Constant c2) {
663        Constant sub_Constant_Constant_value = Constant.create(c1.floatValue() - c2.floatValue());
664    
665        return sub_Constant_Constant_value;
666      }
667      /**
668       * @attribute syn
669       * @aspect ConstantExpression
670       * @declaredat /home/jesper/git/extendj/java4/frontend/ConstantExpression.jrag:202
671       */
672      @ASTNodeAnnotation.Attribute
673      public Constant questionColon(Constant cond, Constant c1, Constant c2) {
674        Constant questionColon_Constant_Constant_Constant_value = Constant.create(cond.booleanValue() ? c1.floatValue() : c2.floatValue());
675    
676        return questionColon_Constant_Constant_Constant_value;
677      }
678      /**
679       * @attribute syn
680       * @aspect ConstantExpression
681       * @declaredat /home/jesper/git/extendj/java4/frontend/ConstantExpression.jrag:326
682       */
683      @ASTNodeAnnotation.Attribute
684      public boolean eqIsTrue(Expr left, Expr right) {
685        boolean eqIsTrue_Expr_Expr_value = left.constant().floatValue() == right.constant().floatValue();
686    
687        return eqIsTrue_Expr_Expr_value;
688      }
689      /**
690       * @attribute syn
691       * @aspect ConstantExpression
692       * @declaredat /home/jesper/git/extendj/java4/frontend/ConstantExpression.jrag:337
693       */
694      @ASTNodeAnnotation.Attribute
695      public boolean ltIsTrue(Expr left, Expr right) {
696        boolean ltIsTrue_Expr_Expr_value = left.constant().floatValue() < right.constant().floatValue();
697    
698        return ltIsTrue_Expr_Expr_value;
699      }
700      /**
701       * @attribute syn
702       * @aspect ConstantExpression
703       * @declaredat /home/jesper/git/extendj/java4/frontend/ConstantExpression.jrag:343
704       */
705      @ASTNodeAnnotation.Attribute
706      public boolean leIsTrue(Expr left, Expr right) {
707        boolean leIsTrue_Expr_Expr_value = left.constant().floatValue() <= right.constant().floatValue();
708    
709        return leIsTrue_Expr_Expr_value;
710      }
711      /**
712       * @attribute syn
713       * @aspect TypeAnalysis
714       * @declaredat /home/jesper/git/extendj/java4/frontend/TypeAnalysis.jrag:217
715       */
716      @ASTNodeAnnotation.Attribute
717      public boolean isFloat() {
718        boolean isFloat_value = true;
719    
720        return isFloat_value;
721      }
722      /**
723       * @attribute syn
724       * @aspect CodeGeneration
725       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:249
726       */
727      @ASTNodeAnnotation.Attribute
728      public byte arrayLoad() {
729        byte arrayLoad_value = Bytecode.FALOAD;
730    
731        return arrayLoad_value;
732      }
733      /**
734       * @attribute syn
735       * @aspect CodeGeneration
736       * @declaredat /home/jesper/git/extendj/java4/backend/CodeGeneration.jrag:380
737       */
738      @ASTNodeAnnotation.Attribute
739      public byte arrayStore() {
740        byte arrayStore_value = Bytecode.FASTORE;
741    
742        return arrayStore_value;
743      }
744      /**
745       * @apilevel internal
746       */
747      protected boolean typeDescriptor_computed = false;
748      /**
749       * @apilevel internal
750       */
751      protected String typeDescriptor_value;
752      /**
753       * @apilevel internal
754       */
755      private void typeDescriptor_reset() {
756        typeDescriptor_computed = false;
757        typeDescriptor_value = null;
758      }
759      /**
760       * @attribute syn
761       * @aspect ConstantPoolNames
762       * @declaredat /home/jesper/git/extendj/java4/backend/ConstantPoolNames.jrag:77
763       */
764      @ASTNodeAnnotation.Attribute
765      public String typeDescriptor() {
766        ASTNode$State state = state();
767        if (typeDescriptor_computed) {
768          return typeDescriptor_value;
769        }
770        boolean intermediate = state.INTERMEDIATE_VALUE;
771        state.INTERMEDIATE_VALUE = false;
772        int num = state.boundariesCrossed;
773        boolean isFinal = this.is$Final();
774        typeDescriptor_value = "F";
775        if (isFinal && num == state().boundariesCrossed) {
776          typeDescriptor_computed = true;
777        } else {
778        }
779        state.INTERMEDIATE_VALUE |= intermediate;
780    
781        return typeDescriptor_value;
782      }
783      /**
784       * @attribute syn
785       * @aspect CreateBCode
786       * @declaredat /home/jesper/git/extendj/java4/backend/CreateBCode.jrag:905
787       */
788      @ASTNodeAnnotation.Attribute
789      public int arrayPrimitiveTypeDescriptor() {
790        int arrayPrimitiveTypeDescriptor_value = 6;
791    
792        return arrayPrimitiveTypeDescriptor_value;
793      }
794      /**
795       * @apilevel internal
796       */
797      protected boolean jvmName_computed = false;
798      /**
799       * @apilevel internal
800       */
801      protected String jvmName_value;
802      /**
803       * @apilevel internal
804       */
805      private void jvmName_reset() {
806        jvmName_computed = false;
807        jvmName_value = null;
808      }
809      /**
810       * @attribute syn
811       * @aspect Java2Rewrites
812       * @declaredat /home/jesper/git/extendj/java4/backend/Java2Rewrites.jrag:36
813       */
814      @ASTNodeAnnotation.Attribute
815      public String jvmName() {
816        ASTNode$State state = state();
817        if (jvmName_computed) {
818          return jvmName_value;
819        }
820        boolean intermediate = state.INTERMEDIATE_VALUE;
821        state.INTERMEDIATE_VALUE = false;
822        int num = state.boundariesCrossed;
823        boolean isFinal = this.is$Final();
824        jvmName_value = "F";
825        if (isFinal && num == state().boundariesCrossed) {
826          jvmName_computed = true;
827        } else {
828        }
829        state.INTERMEDIATE_VALUE |= intermediate;
830    
831        return jvmName_value;
832      }
833      /**
834       * @attribute syn
835       * @aspect Java2Rewrites
836       * @declaredat /home/jesper/git/extendj/java4/backend/Java2Rewrites.jrag:68
837       */
838      @ASTNodeAnnotation.Attribute
839      public String primitiveClassName() {
840        String primitiveClassName_value = "Float";
841    
842        return primitiveClassName_value;
843      }
844      /**
845       * @apilevel internal
846       */
847      protected boolean boxed_computed = false;
848      /**
849       * @apilevel internal
850       */
851      protected TypeDecl boxed_value;
852      /**
853       * @apilevel internal
854       */
855      private void boxed_reset() {
856        boxed_computed = false;
857        boxed_value = null;
858      }
859      /**
860       * @attribute syn
861       * @aspect AutoBoxing
862       * @declaredat /home/jesper/git/extendj/java5/frontend/AutoBoxing.jrag:56
863       */
864      @ASTNodeAnnotation.Attribute
865      public TypeDecl boxed() {
866        ASTNode$State state = state();
867        if (boxed_computed) {
868          return boxed_value;
869        }
870        boolean intermediate = state.INTERMEDIATE_VALUE;
871        state.INTERMEDIATE_VALUE = false;
872        int num = state.boundariesCrossed;
873        boolean isFinal = this.is$Final();
874        boxed_value = lookupType("java.lang", "Float");
875        if (isFinal && num == state().boundariesCrossed) {
876          boxed_computed = true;
877        } else {
878        }
879        state.INTERMEDIATE_VALUE |= intermediate;
880    
881        return boxed_value;
882      }
883      /**
884       * @apilevel internal
885       */
886      public ASTNode rewriteTo() {
887        return super.rewriteTo();
888      }
889    }