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

Unified Diff: pkg/kernel/lib/transformations/closure/info.dart

Issue 2938773003: Add transformLibraries for closure conversion (Closed)
Patch Set: Merge-in lastest changes in master (f71e6fd49b) Created 3 years, 6 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/kernel/lib/transformations/closure/mock.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/kernel/lib/transformations/closure/info.dart
diff --git a/pkg/kernel/lib/transformations/closure/info.dart b/pkg/kernel/lib/transformations/closure/info.dart
index acbb3d21535b93c87b12223e41267d102f153623..2d9c2ca3c90f6f38ea3b78201741b63a3eaa7c94 100644
--- a/pkg/kernel/lib/transformations/closure/info.dart
+++ b/pkg/kernel/lib/transformations/closure/info.dart
@@ -64,13 +64,19 @@ class ClosureInfo extends RecursiveVisitor {
/// Maps the names of all instance methods that may be torn off (aka
/// implicitly closurized) to `${name.name}#get`.
Map<Name, Name> get tearOffGetterNames {
- Map<Name, Name> result = <Name, Name>{};
- for (Name name in declaredInstanceMethodNames) {
- if (invokedGetters.contains(name)) {
- result[name] = new Name("${name.name}#get", name.library);
- }
- }
- return result;
+ // TODO(dmitryas): Add support for tear-offs. When added, uncomment this.
+ //
+ // Map<Name, Name> result = <Name, Name>{};
+ // for (Name name in declaredInstanceMethodNames) {
+ // if (invokedGetters.contains(name)) {
+ // result[name] = new Name("${name.name}#get", name.library);
+ // }
+ // }
+ // return result;
+ //
+ // Currently an empty map is returned, so no tear-offs supporting functions
+ // and getters are generated, and no property-get targets are renamed.
+ return <Name, Name>{};
}
void beginMember(Member member, [FunctionNode function]) {
« no previous file with comments | « no previous file | pkg/kernel/lib/transformations/closure/mock.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698