Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1)

Unified Diff: pkg/compiler/lib/src/compiler.dart

Issue 1723443003: First step of support for parsing and ignoring generic methods. (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Fixes bug with nested type arguments Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « pkg/compiler/lib/src/common/resolution.dart ('k') | pkg/compiler/lib/src/dart2js.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/compiler.dart
diff --git a/pkg/compiler/lib/src/compiler.dart b/pkg/compiler/lib/src/compiler.dart
index 3df2ba45fd807844146bab40c26730f30492ffe5..c69206efacadf471262e530ff04e06897d222f97 100644
--- a/pkg/compiler/lib/src/compiler.dart
+++ b/pkg/compiler/lib/src/compiler.dart
@@ -92,6 +92,7 @@ import 'null_compiler_output.dart' show
import 'parser/diet_parser_task.dart' show
DietParserTask;
import 'parser/element_listener.dart' show
+ ParserOptions,
ScannerOptions;
import 'parser/parser_task.dart' show
ParserTask;
@@ -202,6 +203,8 @@ abstract class Compiler {
final bool useContentSecurityPolicy;
final bool enableExperimentalMirrors;
final bool enableAssertMessage;
+ final bool enableConditionalDirectives;
+ final bool enableGenericMethods;
/**
* The maximum size of a concrete type before it widens to dynamic during
@@ -454,7 +457,8 @@ abstract class Compiler {
this.deferredMapUri: null,
this.dumpInfo: false,
bool useStartupEmitter: false,
- bool enableConditionalDirectives: false,
+ this.enableConditionalDirectives: false,
+ this.enableGenericMethods: false,
this.useContentSecurityPolicy: false,
bool hasIncrementalSupport: false,
this.enableExperimentalMirrors: false,
@@ -516,12 +520,9 @@ abstract class Compiler {
libraryLoader = new LibraryLoaderTask(this),
serialization = new SerializationTask(this),
scanner = new ScannerTask(this),
- dietParser = new DietParserTask(
- this, enableConditionalDirectives: enableConditionalDirectives),
- parser = new ParserTask(
- this, enableConditionalDirectives: enableConditionalDirectives),
- patchParser = new PatchParserTask(
- this, enableConditionalDirectives: enableConditionalDirectives),
+ dietParser = new DietParserTask(this, parsing.parserOptions),
+ parser = new ParserTask(this, parsing.parserOptions),
+ patchParser = new PatchParserTask(this, parsing.parserOptions),
resolver = new ResolverTask(this, backend.constantCompilerTask),
closureToClassMapper = new closureMapping.ClosureTask(this),
checker = new TypeCheckerTask(this),
@@ -2183,6 +2184,13 @@ class _CompilerParsing implements Parsing {
return new ScannerOptions(
canUseNative: compiler.backend.canLibraryUseNative(element.library));
}
+
+ @override
+ ParserOptions get parserOptions {
+ return new ParserOptions(
+ enableConditionalDirectives: compiler.enableConditionalDirectives,
+ enableGenericMethods: compiler.enableGenericMethods);
+ }
}
class GlobalDependencyRegistry extends EagerRegistry {
« no previous file with comments | « pkg/compiler/lib/src/common/resolution.dart ('k') | pkg/compiler/lib/src/dart2js.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698