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

Unified Diff: pkg/analyzer/test/generated/parser_test.dart

Issue 1045553002: Implement the new '??' operator in analyzer. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Fix if_null_precedence_test for unchecked operation. Created 5 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
Index: pkg/analyzer/test/generated/parser_test.dart
diff --git a/pkg/analyzer/test/generated/parser_test.dart b/pkg/analyzer/test/generated/parser_test.dart
index c55fed25a4929e7b96c620e55148e9ca1b105a0d..46c93a0af00d4a39fdc76a460629edf9fff1c402 100644
--- a/pkg/analyzer/test/generated/parser_test.dart
+++ b/pkg/analyzer/test/generated/parser_test.dart
@@ -6,6 +6,7 @@ library engine.parser_test;
import 'package:analyzer/src/generated/ast.dart';
import 'package:analyzer/src/generated/element.dart';
+import 'package:analyzer/src/generated/engine.dart';
import 'package:analyzer/src/generated/error.dart';
import 'package:analyzer/src/generated/incremental_scanner.dart';
import 'package:analyzer/src/generated/parser.dart';
@@ -2388,8 +2389,9 @@ class C {
// Incrementally parse the modified contents.
//
GatheringErrorListener incrementalListener = new GatheringErrorListener();
- IncrementalScanner incrementalScanner = new IncrementalScanner(
- source, new CharSequenceReader(modifiedContents), incrementalListener);
+ AnalysisOptionsImpl options = new AnalysisOptionsImpl();
+ IncrementalScanner incrementalScanner = new IncrementalScanner(source,
+ new CharSequenceReader(modifiedContents), incrementalListener, options);
Token incrementalTokens = incrementalScanner.rescan(
originalTokens, replaceStart, removed.length, added.length);
expect(incrementalTokens, isNotNull);
@@ -7233,10 +7235,11 @@ void''');
}
void test_parseFormalParameterList_prefixedType_partial() {
- FormalParameterList parameterList =
- parse4("parseFormalParameterList", "(io.)", [
- ParserErrorCode.MISSING_IDENTIFIER,
- ParserErrorCode.MISSING_IDENTIFIER]);
+ FormalParameterList parameterList = parse4("parseFormalParameterList",
+ "(io.)", [
+ ParserErrorCode.MISSING_IDENTIFIER,
+ ParserErrorCode.MISSING_IDENTIFIER
+ ]);
expect(parameterList.leftParenthesis, isNotNull);
expect(parameterList.leftDelimiter, isNull);
expect(parameterList.parameters, hasLength(1));
@@ -7246,10 +7249,11 @@ void''');
}
void test_parseFormalParameterList_prefixedType_partial2() {
- FormalParameterList parameterList =
- parse4("parseFormalParameterList", "(io.,a)", [
- ParserErrorCode.MISSING_IDENTIFIER,
- ParserErrorCode.MISSING_IDENTIFIER]);
+ FormalParameterList parameterList = parse4("parseFormalParameterList",
+ "(io.,a)", [
+ ParserErrorCode.MISSING_IDENTIFIER,
+ ParserErrorCode.MISSING_IDENTIFIER
+ ]);
expect(parameterList.leftParenthesis, isNotNull);
expect(parameterList.leftDelimiter, isNull);
expect(parameterList.parameters, hasLength(2));
« no previous file with comments | « pkg/analyzer/test/generated/incremental_scanner_test.dart ('k') | pkg/analyzer/test/generated/resolver_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698