Examples of makeRef()


Examples of com.google.gwt.dev.js.ast.JsName.makeRef()

          // Assign the JsName to the common ancestor
          fragmentAssignment.put(x, newAssignment);
        }
      }

      ctx.replaceMe(name.makeRef(x.getSourceInfo().makeChild(
          JsStringInterner.class, "Interned reference")));

      return false;
    }
View Full Code Here

Examples of com.google.gwt.dev.js.ast.JsName.makeRef()

        finallyBlocksToExitVariables = Maps.put(finallyBlocksToExitVariables,
            x, earlyExitName);
        JsVar var = new JsVar(x.getSourceInfo(), earlyExitName);
        varsToAdd = Lists.add(varsToAdd, var);
      }
      return earlyExitName.makeRef(x.getSourceInfo());
    }

    private JsCatch makeSyntheticCatchBlock(JsTry x) {
      /*
       * catch (e) { e = caught(e); throw e; }
View Full Code Here

Examples of com.google.gwt.dev.js.ast.JsName.makeRef()

      JsName paramName = c.getParameter().getName();

      // caught(e)
      JsInvocation caughtCall = new JsInvocation(info);
      caughtCall.setQualifier(caughtFunction.getName().makeRef(info));
      caughtCall.getArguments().add(paramName.makeRef(info));

      // e = caught(e)
      JsBinaryOperation asg = new JsBinaryOperation(info, JsBinaryOperator.ASG,
          paramName.makeRef(info), caughtCall);
View Full Code Here

Examples of com.google.gwt.dev.js.ast.JsName.makeRef()

      caughtCall.setQualifier(caughtFunction.getName().makeRef(info));
      caughtCall.getArguments().add(paramName.makeRef(info));

      // e = caught(e)
      JsBinaryOperation asg = new JsBinaryOperation(info, JsBinaryOperator.ASG,
          paramName.makeRef(info), caughtCall);

      // throw e
      JsThrow throwStatement = new JsThrow(info, paramName.makeRef(info));

      JsBlock body = new JsBlock(info);
View Full Code Here

Examples of com.google.gwt.dev.js.ast.JsName.makeRef()

      // e = caught(e)
      JsBinaryOperation asg = new JsBinaryOperation(info, JsBinaryOperator.ASG,
          paramName.makeRef(info), caughtCall);

      // throw e
      JsThrow throwStatement = new JsThrow(info, paramName.makeRef(info));

      JsBlock body = new JsBlock(info);
      body.getStatements().add(asg.makeStmt());
      body.getStatements().add(throwStatement);
      c.setBody(body);
View Full Code Here

Examples of com.google.gwt.dev.js.ast.JsName.makeRef()

      JsName name = map.nameForMethod(entryMethod);
      assert name != null;
      SourceInfo sourceInfo = jsprogram.getSourceInfo().makeChild(
          FragmentExtractor.class, "call to entry function " + splitPoint);
      JsInvocation call = new JsInvocation(sourceInfo);
      call.setQualifier(name.makeRef(sourceInfo));
      callStats.add(call.makeStmt());
    }
    return callStats;
  }
View Full Code Here

Examples of com.google.gwt.dev.js.ast.JsName.makeRef()

    JsName loadedMethodName = map.nameForMethod(loadedMethod);
    SourceInfo sourceInfo = jsprogram.getSourceInfo().makeChild(
        FragmentExtractor.class,
        "call to browserLoaderLeftoversFragmentHasLoaded ");
    JsInvocation call = new JsInvocation(sourceInfo);
    call.setQualifier(loadedMethodName.makeRef(sourceInfo));
    List<JsStatement> newStats = Collections.<JsStatement> singletonList(call.makeStmt());
    return newStats;
  }

  /**
 
View Full Code Here

Examples of com.google.gwt.dev.js.ast.JsName.makeRef()

      JsExpression asg = createAssignment(
          topScope.findExistingUnobfuscatableName("$moduleName").makeRef(
              sourceInfo), modName.makeRef(sourceInfo));
      body.getStatements().add(asg.makeStmt());
      asg = createAssignment(topScope.findExistingUnobfuscatableName(
          "$moduleBase").makeRef(sourceInfo), modBase.makeRef(sourceInfo));
      body.getStatements().add(asg.makeStmt());
      JsIf jsIf = new JsIf(sourceInfo);
      body.getStatements().add(jsIf);
      jsIf.setIfExpr(errFn.makeRef(sourceInfo));
      JsTry jsTry = new JsTry(sourceInfo);
View Full Code Here

Examples of com.google.gwt.dev.js.ast.JsName.makeRef()

        typeForStatMap.put(seedFuncStmt, x);

        // setup prototype, assign to temp
        // _ = com_example_foo_Foo.prototype = new com_example_foo_FooSuper();
        JsNameRef lhs = prototype.makeRef(sourceInfo);
        lhs.setQualifier(seedFuncName.makeRef(sourceInfo));
        JsExpression rhs;
        if (x.getSuperClass() != null) {
          JsNew newExpr = new JsNew(sourceInfo);
          JsNameRef superPrototypeRef = names.get(x.getSuperClass()).makeRef(
              sourceInfo);
View Full Code Here

Examples of com.google.gwt.dev.js.ast.JsName.makeRef()

        // _.toString = function(){return this.java_lang_Object_toString();}

        // lhs
        JsName lhsName = objectScope.declareName("toString");
        lhsName.setObfuscatable(false);
        JsNameRef lhs = lhsName.makeRef(sourceInfo);
        lhs.setQualifier(globalTemp.makeRef(sourceInfo));

        // rhs
        JsInvocation call = new JsInvocation(sourceInfo);
        JsNameRef toStringRef = new JsNameRef(sourceInfo,
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.