Package com.google.dart.engine.internal.constant

Examples of com.google.dart.engine.internal.constant.ConstantValueComputer


   * Compute a value for all of the constants in the libraries being analyzed.
   */
  private void performConstantEvaluation() {
    TimeCounterHandle timeCounter = PerformanceStatistics.resolve.start();
    try {
      ConstantValueComputer computer = new ConstantValueComputer(
          typeProvider,
          analysisContext.getDeclaredVariables());
      for (Library library : librariesInCycles) {
        for (Source source : library.getCompilationUnitSources()) {
          try {
            CompilationUnit unit = library.getAST(source);
            if (unit != null) {
              computer.add(unit);
            }
          } catch (AnalysisException exception) {
            AnalysisEngine.getInstance().getLogger().logError(
                "Internal Error: Could not access AST for " + source.getFullName()
                    + " during constant evaluation",
                exception);
          }
        }
      }
      computer.computeValues();
    } finally {
      timeCounter.stop();
    }
  }
View Full Code Here


   * Compute a value for all of the constants in the libraries being analyzed.
   */
  private void performConstantEvaluation() {
    TimeCounterHandle timeCounter = PerformanceStatistics.resolve.start();
    try {
      ConstantValueComputer computer = new ConstantValueComputer(
          typeProvider,
          analysisContext.getDeclaredVariables());
      for (ResolvableLibrary library : librariesInCycle) {
        for (ResolvableCompilationUnit unit : library.getResolvableCompilationUnits()) {
          CompilationUnit ast = unit.getCompilationUnit();
          if (ast != null) {
            computer.add(ast);
          }
        }
      }
      computer.computeValues();
    } finally {
      timeCounter.stop();
    }
  }
View Full Code Here

TOP

Related Classes of com.google.dart.engine.internal.constant.ConstantValueComputer

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.