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

Unified Diff: sdk/lib/_internal/compiler/implementation/ssa/nodes.dart

Issue 11448009: Represent runtime type information as nested lists. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Address comments. Created 8 years 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: sdk/lib/_internal/compiler/implementation/ssa/nodes.dart
diff --git a/sdk/lib/_internal/compiler/implementation/ssa/nodes.dart b/sdk/lib/_internal/compiler/implementation/ssa/nodes.dart
index c6e818b0d3de07361e1da79b4e873b783a42a5df..88718e143fa8eda77f055a8013b33b8a02124012 100644
--- a/sdk/lib/_internal/compiler/implementation/ssa/nodes.dart
+++ b/sdk/lib/_internal/compiler/implementation/ssa/nodes.dart
@@ -2528,18 +2528,20 @@ class HIs extends HInstruction {
final DartType typeExpression;
final bool nullOk;
- HIs.withTypeInfoCall(this.typeExpression, HInstruction expression,
- HInstruction typeInfo, [this.nullOk = false])
- : super(<HInstruction>[expression, typeInfo]);
+ HIs.withArgumentChecks(this.typeExpression,
+ HInstruction expression,
+ List<HInstruction> checks,
+ [this.nullOk = false])
+ : super(<HInstruction>[expression]..addAll(checks));
HIs(this.typeExpression, HInstruction expression, {this.nullOk: false})
: super(<HInstruction>[expression]);
HInstruction get expression => inputs[0];
+ HInstruction getCheck(int index) => inputs[index + 1];
+ int get checkCount => inputs.length - 1;
- HInstruction get typeInfoCall => inputs[1];
-
- bool hasTypeInfo() => inputs.length == 2;
+ bool hasArgumentChecks() => inputs.length >= 1;
HType get guaranteedType => HType.BOOLEAN;

Powered by Google App Engine
This is Rietveld 408576698