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

Unified Diff: pkg/compiler/lib/src/kernel/kelements.dart

Issue 2968383002: Add ConstructorBodyEntity (Closed)
Patch Set: Created 3 years, 5 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/kernel/kelements.dart
diff --git a/pkg/compiler/lib/src/kernel/kelements.dart b/pkg/compiler/lib/src/kernel/kelements.dart
index 30d6f9e83ed615cbdbfa8f5098df4bfea0f4a3c8..1be6bb089c2d6cb6613d89966554fbd53360a127 100644
--- a/pkg/compiler/lib/src/kernel/kelements.dart
+++ b/pkg/compiler/lib/src/kernel/kelements.dart
@@ -164,6 +164,26 @@ class KFactoryConstructor extends KConstructor {
bool get isGenerativeConstructor => false;
}
+class KConstructorBody extends KFunction implements ConstructorBodyEntity {
+ final ConstructorEntity constructor;
+
+ KConstructorBody(int memberIndex, this.constructor)
+ : super(
+ memberIndex,
+ constructor.library,
+ constructor.enclosingClass,
+ constructor.memberName,
+ constructor.parameterStructure,
+ AsyncMarker.SYNC,
+ isStatic: false,
+ isExternal: false);
+
+ @override
+ bool get isFunction => true;
+
+ String get _kind => 'constructor_body';
+}
+
class KMethod extends KFunction {
final bool isAbstract;

Powered by Google App Engine
This is Rietveld 408576698