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

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

Issue 1881013002: Expand ResolvedAst to handle synthetic constructors. (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Turn comment into TODO. Created 4 years, 8 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/compiler/lib/src/serialization/element_serialization.dart
diff --git a/pkg/compiler/lib/src/serialization/element_serialization.dart b/pkg/compiler/lib/src/serialization/element_serialization.dart
index 78228ca41395b8220d86395e999bb1b84fa97a54..b6991c021f38eb5defae934076bf8316c9c17d65 100644
--- a/pkg/compiler/lib/src/serialization/element_serialization.dart
+++ b/pkg/compiler/lib/src/serialization/element_serialization.dart
@@ -105,10 +105,11 @@ class SerializerUtil {
if (element.sourcePosition != null) {
SourceSpan position = element.sourcePosition;
encoder.setInt(Key.OFFSET, position.begin);
- if (position.uri != element.compilationUnit.script.resourceUri) {
- // TODO(johnniwinther): What is the base URI in the case?
- encoder.setUri(Key.URI, element.library.canonicalUri, position.uri);
- }
+ // TODO(johnniwinther): Figure out why the omitted the uri if
+ // `position.uri != element.compilationUnit.script.resourceUri` does not
+ // always work, for instance for LinkedHashMap#_literal.
+ // TODO(johnniwinther): What is the base URI in the case?
+ encoder.setUri(Key.URI, element.library.canonicalUri, position.uri);
int length = position.end - position.begin;
if (element.name.length != length) {
encoder.setInt(Key.LENGTH, length);

Powered by Google App Engine
This is Rietveld 408576698