Package org.allspice.bytecode.instructions

Examples of org.allspice.bytecode.instructions.IfNotEquals0


    Var x = new Var(i1,new TypeName(type)) ;
    MethodDef md = new MethodDef(TypeName.BOOLEAN,"meth",x) ;
    Mark one = new Mark() ;
    md = md.addInstructions(
        new Load(x),
        new IfNotEquals0(TypeCode.getType(type),one),
        new Const(false),
        new Return(TypeCode.BOOLEAN),
        new Nop(one),
        new Const(true),
        new Return(TypeCode.BOOLEAN)
View Full Code Here


  public static void createOr(EvaluationContext context,
      final Expr lhs, final Expr rhs, InstList l) throws CompilerException {
    Mark isOne = new Mark() ;
    Mark end = new Mark() ;
    context.compile(null,lhs, l) ;
    l.add(new IfNotEquals0(context.getTypeCode(lhs),isOne)) ;
    context.compile(null,rhs, l) ;
    l.add(new IfNotEquals0(context.getTypeCode(rhs),isOne)) ;
    l.add(new Const(Boolean.FALSE)) ;
    l.add(new Goto(end)) ;
    l.add(new Nop(isOne)) ;
    l.add(new Const(Boolean.TRUE)) ;
    l.add(new Nop(end)) ;
View Full Code Here

    l.add(new Nop(beginmark)) ;
    for(Statement s: thenst) {
      newContext.compile(s,l) ;
    }
    context.compile(null,cond, l) ;
    l.add(new IfNotEquals0(context.getTypeCode(cond),beginmark)) ;
    l.add(new Nop(endmark)) ;
  }
View Full Code Here

TOP

Related Classes of org.allspice.bytecode.instructions.IfNotEquals0

Copyright © 2018 www.massapicom. 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.