public class TranspilationPasses extends Object
Modifier and Type | Method and Description |
---|---|
static void |
addEs2016Passes(List<PassFactory> passes) |
static void |
addEs2017Passes(List<PassFactory> passes) |
static void |
addEs6EarlyPasses(List<PassFactory> passes)
Adds all the early ES6 transpilation passes, which go before the Dart pass.
|
static void |
addEs6LatePasses(List<PassFactory> passes)
Adds all the late ES6 transpilation passes, which go after the Dart pass.
|
static void |
addEs6ModulePass(List<PassFactory> passes) |
static void |
addPostCheckPasses(List<PassFactory> passes) |
static void |
addRewritePolyfillPass(List<PassFactory> passes)
Adds the pass to inject ES6 polyfills, which goes after the late ES6 passes.
|
public static void addEs6ModulePass(List<PassFactory> passes)
public static void addEs2017Passes(List<PassFactory> passes)
public static void addEs2016Passes(List<PassFactory> passes)
public static void addEs6EarlyPasses(List<PassFactory> passes)
Includes ES6 features that are straightforward to transpile. We won't handle them natively in the rest of the compiler, so we always transpile them, even if the output language is also ES6.
public static void addEs6LatePasses(List<PassFactory> passes)
Includes ES6 features that are best handled natively by the compiler. As we convert more passes to handle these features, we will be moving the transpilation later in the compilation, and eventually only transpiling when the output is lower than ES6.
public static void addRewritePolyfillPass(List<PassFactory> passes)
public static void addPostCheckPasses(List<PassFactory> passes)
Copyright © 2009-2017 Google. All Rights Reserved.