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

Issue 810473003: dart2js: Fix of deferred static functions. (Closed)

Created:
6 years ago by sigurdm
Modified:
6 years ago
Reviewers:
floitsch
CC:
reviews_dartlang.org
Target Ref:
refs/remotes/git-svn
Visibility:
Public.

Description

dart2js: Fix of deferred static functions. When deferred static functions go to a different output hunk than the class they are defined in the emitter got problems with outputting them. We could say that static functions always go to the same output-unit as their class, and this is needed to support reflection. But we already handle it that way when reflection is needed. In deferred_load.dart: void addLiveInstanceMember(Element element) { if (!compiler.enqueuer.resolution.hasBeenResolved(element)) return; if (!isMirrorUsage && !element.isInstanceMember) return; collectDependencies(element.implementation); } R=floitsch@google.com Committed: https://code.google.com/p/dart/source/detail?r=42389

Patch Set 1 : #

Total comments: 2

Patch Set 2 : Improve tests #

Unified diffs Side-by-side diffs Delta from patch set Stats (+107 lines, -2 lines) Patch
M pkg/compiler/lib/src/js_emitter/old_emitter/emitter.dart View 1 chunk +4 lines, -2 lines 0 comments Download
A tests/language/deferred_static_seperate_lib1.dart View 1 1 chunk +51 lines, -0 lines 0 comments Download
A tests/language/deferred_static_seperate_lib2.dart View 1 1 chunk +22 lines, -0 lines 0 comments Download
A tests/language/deferred_static_seperate_test.dart View 1 1 chunk +30 lines, -0 lines 0 comments Download

Messages

Total messages: 6 (2 generated)
sigurdm
6 years ago (2014-12-16 11:55:31 UTC) #3
floitsch
LGTM. https://codereview.chromium.org/810473003/diff/20001/tests/language/deferred_static_seperate_lib1.dart File tests/language/deferred_static_seperate_lib1.dart (right): https://codereview.chromium.org/810473003/diff/20001/tests/language/deferred_static_seperate_lib1.dart#newcode19 tests/language/deferred_static_seperate_lib1.dart:19: static var foo = const {}; use different ...
6 years ago (2014-12-16 12:19:45 UTC) #4
sigurdm
https://codereview.chromium.org/810473003/diff/20001/tests/language/deferred_static_seperate_lib1.dart File tests/language/deferred_static_seperate_lib1.dart (right): https://codereview.chromium.org/810473003/diff/20001/tests/language/deferred_static_seperate_lib1.dart#newcode19 tests/language/deferred_static_seperate_lib1.dart:19: static var foo = const {}; On 2014/12/16 12:19:45, ...
6 years ago (2014-12-16 13:02:51 UTC) #5
sigurdm
6 years ago (2014-12-16 13:14:43 UTC) #6
Message was sent while issue was closed.
Committed patchset #2 (id:40001) manually as 42389 (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698