Examples of astore()


Examples of anvil.codec.Code.astore()

  {
    Code code = context.getCode();
    _index = code.addLocal();
    if (!_escaped) {
      code.getstatic(code.getPool().addFieldRef(context.TYPE_ANY, "UNDEFINED", "Lanvil/core/Any;"));
      code.astore(_index);
    }
  }

  public int getTypeRef(ConstantPool pool)
  {
View Full Code Here

Examples of anvil.codec.Code.astore()

  public void compile(ByteCompiler context)
  {
    Code code = context.getCode();
    int lock = code.addLocal();
    _expression.compile(context, Expression.GET);
    code.astore(lock);
    code.aload(lock);
    code.monitorenter();
    ExceptionHandler handler = code.startExceptionHandler(true);
    _handler = handler;
    if (_statement == null) {
View Full Code Here

Examples of anvil.codec.Code.astore()

      handler.jumpOut();
    }
    handler.endProtectedRegion();
    handler.startCatch(0);
    int thrown = code.addLocal();
    code.astore(thrown);
    handler.callFinally();
    code.aload(thrown);
    code.athrow();
    handler.endCatches();
    _handler = null;
View Full Code Here

Examples of anvil.codec.Code.astore()

    handler.endCatches();
    _handler = null;

    handler.startFinally();
    int returnto = code.addLocal();
    code.astore(returnto);
    code.aload(lock);
    code.monitorexit();
    code.ret(returnto);
    handler.endFinally();
View Full Code Here

Examples of anvil.codec.Code.astore()

    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));
    code.invokevirtual(pool.addMethodRef(context.TYPE_ANY, "toBoolean", "()Z"));
    code.ireturn();
View Full Code Here

Examples of anvil.codec.Code.astore()

      // catch
      if (_catches > 0) {
        handler.startCatch(code.getPool().addClass("anvil/script/ScriptException"));
        int l_throwable = code.addLocal();
        int l_data = code.addLocal();
        code.astore(l_throwable);
        code.aload(l_throwable);
        code.invokevirtual(code.getPool().addMethodRef("anvil/script/ScriptException", "getData", "()Lanvil/core/Any;"));
        code.astore(l_data);
        for(int i=0; i<_catches; i++) {
          _catch[i].compile(context, handler, l_data);
View Full Code Here

Examples of anvil.codec.Code.astore()

        int l_throwable = code.addLocal();
        int l_data = code.addLocal();
        code.astore(l_throwable);
        code.aload(l_throwable);
        code.invokevirtual(code.getPool().addMethodRef("anvil/script/ScriptException", "getData", "()Lanvil/core/Any;"));
        code.astore(l_data);
        for(int i=0; i<_catches; i++) {
          _catch[i].compile(context, handler, l_data);
        }
        code.aload(l_throwable);
        code.athrow();
View Full Code Here

Examples of anvil.codec.Code.astore()

      handler.endProtectedRegion();

      if (_finally != null) {
        handler.startCatch(0);
        int thrown = code.addLocal();
        code.astore(thrown);
        handler.callFinally();
        code.aload(thrown);
        code.athrow();
      }
      handler.endCatches();
View Full Code Here

Examples of anvil.codec.Code.astore()

      // finally
      if (_finally != null) {
        handler.startFinally();
        int returnto = code.addLocal();
        code.astore(returnto);
        _finally.compile(context);
        if (!_finally.isBlocked()) {
          code.ret(returnto);
        }
        handler.endFinally();
View Full Code Here

Examples of anvil.codec.Code.astore()

    switch(child.typeOf()) {
    case Node.EXPR_VARIABLE:
      {
        final int tmp = code.addLocal();
        child.compile(context, GET);
        code.astore(tmp);
        child.compile(context, new Node() {
          public void compile(ByteCompiler context, int operation)
          {
            Code code = context.getCode();
            code.aload(tmp);
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.