Package javassist.compiler.ast

Examples of javassist.compiler.ast.ASTree.accept()


/*  584 */     } else if (token == 33) {
/*  585 */       booleanExpr(expr);
/*  586 */     } else if (token == 67) {
/*  587 */       fatal();
/*      */     } else {
/*  589 */       oprand.accept(this);
/*  590 */       if ((!isConstant(expr, token, oprand)) &&
/*  591 */         ((token == 45) || (token == 126)) &&
/*  592 */         (CodeGen.isP_INT(this.exprType)))
/*  593 */         this.exprType = 324;
/*      */     }
View Full Code Here


/*  647 */         targetClass = this.resolver.lookupClass(((Symbol)e.oprand1()).get(), false);
/*      */       }
/*  650 */       else if (op == 46) {
/*  651 */         ASTree target = e.oprand1();
/*      */         try {
/*  653 */           target.accept(this);
/*      */         }
/*      */         catch (NoFieldException nfe) {
/*  656 */           if (nfe.getExpr() != target) {
/*  657 */             throw nfe;
/*      */           }
View Full Code Here

/*      */   public void atMethodArgs(ASTList args, int[] types, int[] dims, String[] cnames) throws CompileError
/*      */   {
/*  730 */     int i = 0;
/*  731 */     while (args != null) {
/*  732 */       ASTree a = args.head();
/*  733 */       a.accept(this);
/*  734 */       types[i] = this.exprType;
/*  735 */       dims[i] = this.arrayDim;
/*  736 */       cnames[i] = this.className;
/*  737 */       i++;
/*  738 */       args = args.tail();
View Full Code Here

/* 352 */             i++;
/*     */           }
/*     */         }
/*     */       }
/*     */       else {
/* 357 */         a.accept(this);
/* 358 */         types[i] = this.exprType;
/* 359 */         dims[i] = this.arrayDim;
/* 360 */         cnames[i] = this.className;
/* 361 */         i++;
/*     */       }
View Full Code Here

/*  425 */       ASTree s = size.head();
/*  426 */       if (s == null) {
/*      */         break;
/*      */       }
/*  429 */       count++;
/*  430 */       s.accept(this);
/*  431 */       if (this.exprType != 324) {
/*  432 */         throw new CompileError("bad type for array size");
/*      */       }
/*      */     }
/*      */
View Full Code Here

/*  491 */         if (((target instanceof Keyword)) &&
/*  492 */           (((Keyword)target).get() == 336))
/*  493 */           isSpecial = true;
/*      */         try
/*      */         {
/*  496 */           target.accept(this);
/*      */         }
/*      */         catch (NoFieldException nfe) {
/*  499 */           if (nfe.getExpr() != target) {
/*  500 */             throw nfe;
/*      */           }
View Full Code Here

/*      */   public void atMethodArgs(ASTList args, int[] types, int[] dims, String[] cnames) throws CompileError
/*      */   {
/*  716 */     int i = 0;
/*  717 */     while (args != null) {
/*  718 */       ASTree a = args.head();
/*  719 */       a.accept(this);
/*  720 */       types[i] = this.exprType;
/*  721 */       dims[i] = this.arrayDim;
/*  722 */       cnames[i] = this.className;
/*  723 */       i++;
/*  724 */       args = args.tail();
View Full Code Here

/*  860 */     boolean is_static = this.resultStatic;
/*  861 */     ASTree cexpr = TypeChecker.getConstantFieldValue(f);
/*  862 */     if (cexpr == null) {
/*  863 */       atFieldRead(f, is_static);
/*      */     } else {
/*  865 */       cexpr.accept(this);
/*  866 */       setFieldType(f.getFieldInfo2());
/*      */     }
/*      */   }
/*      */
/*      */   private void atArrayLength(ASTree expr) throws CompileError {
View Full Code Here

/*  332 */       } else if (isPlusPlusExpr(expr)) {
/*  333 */         Expr e = (Expr)expr;
/*  334 */         atPlusPlus(e.getOperator(), e.oprand1(), e, false);
/*      */       }
/*      */       else {
/*  337 */         expr.accept(this);
/*  338 */         if (is2word(this.exprType, this.arrayDim))
/*  339 */           this.bytecode.addOpcode(88);
/*  340 */         else if (this.exprType != 344)
/*  341 */           this.bytecode.addOpcode(87);
/*      */       }
View Full Code Here

/*  345 */       ASTList list = st;
/*  346 */       while (list != null) {
/*  347 */         ASTree h = list.head();
/*  348 */         list = list.tail();
/*  349 */         if (h != null)
/*  350 */           h.accept(this);
/*      */       }
/*      */     }
/*  353 */     else if (op == 320) {
/*  354 */       atIfStmnt(st);
/*  355 */     } else if ((op == 346) || (op == 311)) {
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.