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

Unified Diff: pkg/compiler/lib/src/js_model/elements.dart

Issue 2994353002: Fix the locals lookup of variables and partial implementation of boxing of variables.
Patch Set: Created 3 years, 4 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/js_model/closure_visitors.dart ('k') | pkg/compiler/lib/src/js_model/js_strategy.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/js_model/elements.dart
diff --git a/pkg/compiler/lib/src/js_model/elements.dart b/pkg/compiler/lib/src/js_model/elements.dart
index 36e690187c7382bae2dca60dbcef2b4947aa6586..f91a3fda8225adb72dc0484de78962f73c291e0a 100644
--- a/pkg/compiler/lib/src/js_model/elements.dart
+++ b/pkg/compiler/lib/src/js_model/elements.dart
@@ -319,7 +319,8 @@ class JClass implements ClassEntity, IndexedClass {
JClass(this.library, this.classIndex, this.name, {this.isAbstract});
- @override
+ /// True if this class is a class created to represent the semantics of a Dart
+ /// closure.
bool get isClosure => false;
String toString() => '${jsElementPrefix}class($name)';
@@ -547,9 +548,16 @@ class JField extends JMember implements FieldEntity, IndexedField {
class JClosureCallMethod extends JMethod {
JClosureCallMethod(int memberIndex, KernelClosureClass containingClass,
ParameterStructure parameterStructure, AsyncMarker asyncMarker)
- : super(memberIndex, containingClass.library, containingClass, Names.call,
- parameterStructure, asyncMarker,
- isStatic: false, isExternal: false, isAbstract: false);
+ : super(
+ memberIndex,
+ containingClass.closureClassEntity.library,
+ containingClass.closureClassEntity,
+ Names.call,
+ parameterStructure,
+ asyncMarker,
+ isStatic: false,
+ isExternal: false,
+ isAbstract: false);
String get _kind => 'closure_call';
}
« no previous file with comments | « pkg/compiler/lib/src/js_model/closure_visitors.dart ('k') | pkg/compiler/lib/src/js_model/js_strategy.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698