Package com.google.gwt.dev.jjs.ast

Examples of com.google.gwt.dev.jjs.ast.JProgram


    // found here will have already been logged by AbstractCompiler.
    //
    checkForErrors(logger, goldenCuds, false);

    PerfLogger.start("Build AST");
    JProgram jprogram = new JProgram();
    JsProgram jsProgram = new JsProgram();

    try {
      /*
       * (1) Build a flattened map of TypeDeclarations => JType. The resulting
View Full Code Here


    try {
      PerfLogger.start("deserialize");
      ByteArrayInputStream bais = new ByteArrayInputStream(serializedAst);
      ObjectInputStream is;
      is = new ObjectInputStream(bais);
      JProgram jprogram = (JProgram) is.readObject();
      JsProgram jsProgram = (JsProgram) is.readObject();
      return new AST(jprogram, jsProgram);
    } catch (IOException e) {
      throw new RuntimeException(
          "Should be impossible for memory based streams", e);
View Full Code Here

      // Library construction does not need to care whether their are or are not any entry points.
    }

    @Override
    protected void createJProgram(CompilerContext compilerContext) {
      jprogram = new JProgram(compilerContext.getMinimalRebuildCache(), false);
    }
View Full Code Here

      }
    }

    @Override
    protected void createJProgram(CompilerContext compilerContext) {
      jprogram = new JProgram(compilerContext.getMinimalRebuildCache());
    }
View Full Code Here

      public StandardGeneratorContext getGeneratorContext() {
        return null;
      }
    };

    JProgram jprogram = new JProgram(compilerContext.getMinimalRebuildCache());
    JsProgram jsProgram = new JsProgram();
    UnifyAst unifyAst = new UnifyAst(logger, compilerContext, jprogram, jsProgram, rpo);
    unifyAst.buildEverything();

    // Compute all super type/sub type info
    jprogram.typeOracle.computeBeforeAST(StandardTypes.createFrom(jprogram),
        jprogram.getDeclaredTypes(), jprogram.getModuleDeclaredTypes());

    // (3) Perform Java AST normalizations.
    FixAssignmentsToUnboxOrCast.exec(jprogram);

    /*
 
View Full Code Here

          JsniCollector.reportJsniError(info, methodDecl,
              "Badly formatted native reference '" + ident + "'");
          return null;
        }

        JProgram prog = program;

        return JsniRefLookup.findJsniRefTarget(parsed, prog,
            new JsniRefLookup.ErrorReporter() {
              public void reportError(String error) {
                JsniCollector.reportJsniError(info, methodDecl, error);
View Full Code Here

        WebModeCompilerFrontEnd.getCompilationUnitDeclarations(logger, allRootTypes
            .toArray(new String[allRootTypes.size()]), rpo, TypeLinker.NULL_TYPE_LINKER).compiledUnits;

    CorrelationFactory correlator = DummyCorrelationFactory.INSTANCE;
    JsProgram jsProgram = new JsProgram(correlator);
    JProgram jprogram = new JProgram(correlator);
    TypeMap typeMap = new TypeMap(jprogram);
    TypeDeclaration[] allTypeDeclarations = BuildTypeMap.exec(typeMap, goldenCuds, jsProgram);
    // BuildTypeMap can uncover syntactic JSNI errors; report & abort
    checkForErrors(logger, goldenCuds);
View Full Code Here

        }
      }
      logger.log(TreeLogger.INFO, (System.currentTimeMillis() - start) + " time to get all types");

      start = System.currentTimeMillis();
      JProgram jprogram = buildGenerateJavaAst(logger, module, compilationState);
      logger.log(TreeLogger.INFO, (System.currentTimeMillis() - start) + " time to build old AST");

      for (JDeclaredType genJavaAstType : jprogram.getDeclaredTypes()) {
        String typeName = genJavaAstType.getName();
        if ("com.google.gwt.core.client.JavaScriptObject".equals(typeName)) {
          // Known mismatch; genJavaAst version implements all JSO interfaces.
          continue;
        }
View Full Code Here

    // found here will have already been logged by AbstractCompiler.
    checkForErrors(logger, goldenCuds, false);

    CorrelationFactory correlator = options.isSoycExtra()
        ? RealCorrelationFactory.INSTANCE : DummyCorrelationFactory.INSTANCE;
    JProgram jprogram = new JProgram(correlator);
    JsProgram jsProgram = new JsProgram(correlator);

    try {
      /*
       * (1) Build a flattened map of TypeDeclarations => JType. The resulting
View Full Code Here

        System.out.println("------------------------------------------------------------");
        System.out.println("Properties: " + permutation.prettyPrint());
      }

      AST ast = unifiedAst.getFreshAst();
      JProgram jprogram = ast.getJProgram();
      JsProgram jsProgram = ast.getJsProgram();

      Map<StandardSymbolData, JsName> symbolTable = new TreeMap<StandardSymbolData, JsName>(
          new SymbolData.ClassIdentComparator());
View Full Code Here

TOP

Related Classes of com.google.gwt.dev.jjs.ast.JProgram

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.