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

Unified Diff: pkg/analyzer_experimental/lib/analyzer.dart

Issue 22865011: Fix warnings in analyzer_experimental (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 4 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 | « no previous file | pkg/analyzer_experimental/lib/options.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analyzer_experimental/lib/analyzer.dart
diff --git a/pkg/analyzer_experimental/lib/analyzer.dart b/pkg/analyzer_experimental/lib/analyzer.dart
index 644009c557e4adb73712692e0f1405cb6cd1f64f..a88c94c2060b037c77b9500cb1837b6f55fa18ad 100644
--- a/pkg/analyzer_experimental/lib/analyzer.dart
+++ b/pkg/analyzer_experimental/lib/analyzer.dart
@@ -11,7 +11,6 @@ import 'package:path/path.dart' as pathos;
import 'src/error.dart';
import 'src/generated/ast.dart';
import 'src/generated/error.dart';
-import 'src/generated/java_io.dart';
import 'src/generated/parser.dart';
import 'src/generated/scanner.dart';
import 'src/generated/source_io.dart';
@@ -49,13 +48,7 @@ CompilationUnit parseDartFile(String path) {
/// Converts an AST node representing a string literal into a [String].
String stringLiteralToString(StringLiteral literal) {
- if (literal is AdjacentStrings) {
- return literal.strings.map(stringLiteralToString).join();
- } else if (literal is SimpleStringLiteral) {
- return literal.value;
- } else {
- throw new ArgumentError("Can't convert $literal to a Dart string.");
- }
+ return literal.stringValue;
}
/// A simple error listener that collects errors into an [AnalysisErrorGroup].
« no previous file with comments | « no previous file | pkg/analyzer_experimental/lib/options.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698