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

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

Issue 925943002: Refactor SourceFile, SourceFileProvider and SourceLocation. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Updated cf. comments. Created 5 years, 10 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/source_file_provider.dart ('k') | pkg/dart2js_incremental/lib/library_updater.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/ssa/builder.dart
diff --git a/pkg/compiler/lib/src/ssa/builder.dart b/pkg/compiler/lib/src/ssa/builder.dart
index c67afb43fafc5ca3fafa673473625c65c1d21280..404ac8d0ee7e51974e1109818e29c17abc66ff63 100644
--- a/pkg/compiler/lib/src/ssa/builder.dart
+++ b/pkg/compiler/lib/src/ssa/builder.dart
@@ -1152,8 +1152,8 @@ class SsaBuilder extends ResolvedVisitor {
}
void checkValidSourceFileLocation(
- SourceFileLocation location, SourceFile sourceFile, int offset) {
- if (!location.isValid()) {
+ SourceLocation location, SourceFile sourceFile, int offset) {
+ if (!location.isValid) {
throw MessageKind.INVALID_SOURCE_FILE_LOCATION.message(
{'offset': offset,
'fileName': sourceFile.filename,
@@ -2515,16 +2515,16 @@ class SsaBuilder extends ResolvedVisitor {
sourceFileLocationForEndToken(node));
}
- SourceFileLocation sourceFileLocationForBeginToken(ast.Node node) =>
+ SourceLocation sourceFileLocationForBeginToken(ast.Node node) =>
sourceFileLocationForToken(node, node.getBeginToken());
- SourceFileLocation sourceFileLocationForEndToken(ast.Node node) =>
+ SourceLocation sourceFileLocationForEndToken(ast.Node node) =>
sourceFileLocationForToken(node, node.getEndToken());
- SourceFileLocation sourceFileLocationForToken(ast.Node node, Token token) {
+ SourceLocation sourceFileLocationForToken(ast.Node node, Token token) {
SourceFile sourceFile = currentSourceFile();
- SourceFileLocation location =
- new TokenSourceFileLocation(sourceFile, token, sourceElement.name);
+ SourceLocation location =
+ new TokenSourceLocation(sourceFile, token, sourceElement.name);
checkValidSourceFileLocation(location, sourceFile, token.charOffset);
return location;
}
« no previous file with comments | « pkg/compiler/lib/src/source_file_provider.dart ('k') | pkg/dart2js_incremental/lib/library_updater.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698