Examples of if_eq()


Examples of anvil.codec.Code.if_eq()

    super.compile(context, GET);
    Code code = context.getCode();
    code.invokevirtual(code.getPool().addMethodRef(context.TYPE_ANY,
      "compareTo", "(Lanvil/core/Any;)I"));
    if (operation == GET_BOOLEAN) {
      Source isfalse = code.if_eq();
      code.iconst(true);
      Source toend = code.go_to();
      isfalse.bind();
      code.iconst(false);
      toend.bind();
View Full Code Here

Examples of anvil.codec.Code.if_eq()

  public void compile(ByteCompiler context, int operation)
  {
    Code code = context.getCode();
    _left.compile(context, GET_BOOLEAN);
    code.dup();
    Source source = code.if_eq();
    code.pop();
    _right.compile(context, GET_BOOLEAN);
    source.bind();
    if (operation != GET_BOOLEAN) {
      context.boolean2any();
View Full Code Here

Examples of anvil.codec.Code.if_eq()

          child.compile(context, Node.GET_TYPE);
          code.invokevirtual(pool.addMethodRef(context.TYPE_ANY, "isInstanceOf", "(Lanvil/script/Type;)Z"));
        } else {
          child.compile(context, Node.GET_BOOLEAN);
        }
        isfalse = code.if_eq();
        code.go_to(istrue);
      }
     
      istrue.bind();
     
View Full Code Here

Examples of anvil.codec.Code.if_eq()

      _endscope = code.getSource();
      if (_condition.needLineNumbers()) {
        context.location(_condition.getLocation());
      }
      _condition.compile(context, Expression.GET_BOOLEAN);
      code.if_eq(_endscope);
      _statement.compile(context);
      if (!_statement.isBlocked()) {
        code.go_to(_startscope);
      }
      _startscope.bind(start);
View Full Code Here

Examples of anvil.codec.Code.if_eq()

            String name = target.getName().substring(prefixLength);
            if (name.hashCode() == kase.getKey()) {
              code.aload(l_attr);
              code.astring(name);
              code.invokevirtual(sig_equals);
              Source isfalse = code.if_eq();
              code.self();
              context.compileArgumentList(target, nodes1, l_context);
              code.invokevirtual(target.getTypeRef(pool));
              if (castToBoolean) {
                code.invokevirtual(sig_toBoolean);
View Full Code Here

Examples of anvil.codec.Code.if_eq()

        for(int i=0; i<n; i++) {
          MethodStatement target = methods[i];
          code.aload(l_attr);
          code.astring(target.getName().substring(prefixLength));
          code.invokevirtual(sig_equals);
          Source isfalse = code.if_eq();
          code.self();
          context.compileArgumentList(target, nodes1, l_context);
          code.invokevirtual(target.getTypeRef(pool));
          if (castToBoolean) {
            code.invokevirtual(sig_toBoolean);
View Full Code Here

Examples of anvil.codec.Code.if_eq()

    case Expression.IS_DYNAMIC:
      if (_condition.needLineNumbers()) {
        context.location(_condition.getLocation());
      }
      _condition.compile(context, Expression.GET_BOOLEAN);
      Source to_then = code.if_eq();
      _thenStatements.compile(context);
      if (_elseStatements != null) {
        Source to_end = code.go_to();
        to_then.bind();
        _elseStatements.compile(context);
View Full Code Here

Examples of anvil.codec.Code.if_eq()

    ConstantPool pool = code.getPool();
    context.pushCode(code);
    code.addLocal();
    code.aload(1);
    code.instance_of(context.TYPE_ANY);
    Source isfalse = code.if_eq();
    code.invokestatic(pool.addMethodRef(context.TYPE_CONTEXT, "getInstance", "()Lanvil/script/Context;"));
    code.astore(code.addLocal());
    code.self();
    context.compileArgumentList(function, CAST_P1_NODE, 2);
    code.invokevirtual(function.getTypeRef(pool));
View Full Code Here

Examples of anvil.codec.Code.if_eq()

  public void compile(ByteCompiler context, int operation)
  {
    getChild(0).compile(context, GET_BOOLEAN);
    Code code = context.getCode();
    Source isfalse = code.if_eq();
    getChild(1).compile(context, operation);
    Source out = code.go_to();
    code.popop();
    isfalse.bind();
    getChild(2).compile(context, operation);
View Full Code Here

Examples of anvil.codec.Code.if_eq()

      case Expression.IS_TRUE:
        break;

      case Expression.IS_DYNAMIC:
        _condition.compile(context, Expression.GET_BOOLEAN);
        code.if_eq(_endscope);
        break;
      }
    }

    _statement.compile(context);
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.