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

Issue 2235373003: Fix summary handling of unresolved imports, exports, and parts. (Closed)

Created:
4 years, 4 months ago by Paul Berry
Modified:
4 years, 4 months ago
Reviewers:
Brian Wilkerson
CC:
reviews_dartlang.org
Base URL:
git@github.com:dart-lang/sdk.git@master
Target Ref:
refs/heads/master
Visibility:
Public.

Description

Fix summary handling of unresolved imports, exports, and parts. Previously this was working for a few use cases by dumb luck, but it wasn't well tested and became broken by b29c6bf33000ca129987edffe9e5df0fde793f3b. This CL fixes it for real and adds tests to verify the fix. Note that there is a change to how we represent an unresolved import/export: instead of storing a URI_EXISTS modifier in the element model, we simply mark the imported library element as synthetic. (This library element existed anyway; we just weren't marking it as synthetic). This makes it easy to tie in with summaries, since it is easy for the resynthesizer to detect that the library doesn't exist at the time the library handle is resolved. R=brianwilkerson@google.com Committed: https://github.com/dart-lang/sdk/commit/052a6c867de08e493127e5aaa4d02941ac31d2f8

Patch Set 1 #

Total comments: 2

Patch Set 2 : Simplify `allowMissingFiles` #

Unified diffs Side-by-side diffs Delta from patch set Stats (+180 lines, -132 lines) Patch
M pkg/analyzer/doc/tasks.html View 1 chunk +1 line, -0 lines 0 comments Download
M pkg/analyzer/lib/dart/element/element.dart View 2 chunks +0 lines, -10 lines 0 comments Download
M pkg/analyzer/lib/src/dart/element/builder.dart View 3 chunks +0 lines, -3 lines 0 comments Download
M pkg/analyzer/lib/src/dart/element/element.dart View 4 chunks +1 line, -42 lines 0 comments Download
M pkg/analyzer/lib/src/dart/element/handle.dart View 2 chunks +0 lines, -6 lines 0 comments Download
M pkg/analyzer/lib/src/dart/resolver/scope.dart View 2 chunks +4 lines, -2 lines 0 comments Download
M pkg/analyzer/lib/src/generated/resolver.dart View 5 chunks +14 lines, -14 lines 0 comments Download
M pkg/analyzer/lib/src/summary/index_unit.dart View 2 chunks +3 lines, -3 lines 0 comments Download
M pkg/analyzer/lib/src/summary/resynthesize.dart View 7 chunks +34 lines, -23 lines 0 comments Download
M pkg/analyzer/lib/src/task/dart.dart View 4 chunks +9 lines, -1 line 0 comments Download
M pkg/analyzer/test/src/summary/resynthesize_ast_test.dart View 1 7 chunks +37 lines, -10 lines 0 comments Download
M pkg/analyzer/test/src/summary/resynthesize_test.dart View 1 9 chunks +27 lines, -12 lines 0 comments Download
M pkg/analyzer/test/src/summary/summary_common.dart View 3 chunks +49 lines, -6 lines 0 comments Download
M pkg/analyzer/tool/task_dependency_graph/tasks.dot View 1 chunk +1 line, -0 lines 0 comments Download

Messages

Total messages: 6 (2 generated)
Paul Berry
4 years, 4 months ago (2016-08-11 23:15:16 UTC) #2
Brian Wilkerson
lgtm https://codereview.chromium.org/2235373003/diff/1/pkg/analyzer/test/src/summary/resynthesize_test.dart File pkg/analyzer/test/src/summary/resynthesize_test.dart (right): https://codereview.chromium.org/2235373003/diff/1/pkg/analyzer/test/src/summary/resynthesize_test.dart#newcode53 pkg/analyzer/test/src/summary/resynthesize_test.dart:53: * Tests may set this to `true` to ...
4 years, 4 months ago (2016-08-11 23:49:36 UTC) #3
Paul Berry
https://codereview.chromium.org/2235373003/diff/1/pkg/analyzer/test/src/summary/resynthesize_test.dart File pkg/analyzer/test/src/summary/resynthesize_test.dart (right): https://codereview.chromium.org/2235373003/diff/1/pkg/analyzer/test/src/summary/resynthesize_test.dart#newcode53 pkg/analyzer/test/src/summary/resynthesize_test.dart:53: * Tests may set this to `true` to indicate ...
4 years, 4 months ago (2016-08-12 20:56:51 UTC) #4
Paul Berry
4 years, 4 months ago (2016-08-12 20:59:55 UTC) #6
Message was sent while issue was closed.
Committed patchset #2 (id:20001) manually as
052a6c867de08e493127e5aaa4d02941ac31d2f8 (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698