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

Unified Diff: pkg/compiler/lib/src/cps_ir/cps_ir_nodes.dart

Issue 1180973003: dart2js cps: Support function types in 'is' and 'as' operators. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Update doc comment for TypeCast Created 5 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
Index: pkg/compiler/lib/src/cps_ir/cps_ir_nodes.dart
diff --git a/pkg/compiler/lib/src/cps_ir/cps_ir_nodes.dart b/pkg/compiler/lib/src/cps_ir/cps_ir_nodes.dart
index 33ddf42ae34e5a423820f10242101cb3cd582983..3c735d1aeae6649b17f3e168186c96f59572605c 100644
--- a/pkg/compiler/lib/src/cps_ir/cps_ir_nodes.dart
+++ b/pkg/compiler/lib/src/cps_ir/cps_ir_nodes.dart
@@ -364,7 +364,7 @@ class InvokeConstructor extends Expression implements Invoke {
/// An "is" type test.
///
-/// Returns `true` if [value] not `null` and is an instance of [type].
+/// Returns `true` if [value] is an instance of [type].
///
/// [type] must not be the [Object], `dynamic` or [Null] types (though it might
/// be a type variable containing one of these types). This design is chosen
@@ -380,6 +380,9 @@ class TypeTest extends Primitive {
/// If [type] is a [TypeVariableType], this is a singleton list with
/// the internal representation of the type held in that type variable.
///
+ /// If [type] is a [FunctionType], this is a singleton list with the
+ /// internal representation of that type,
+ ///
/// Otherwise the list is empty.
final List<Reference<Primitive>> typeArguments;
@@ -406,14 +409,7 @@ class TypeCast extends Expression {
Reference<Primitive> value;
final DartType type;
- /// If [type] is an [InterfaceType], this holds the internal representation of
- /// the type arguments to [type]. Since these may reference type variables
- /// from the enclosing class, they are not constant.
- ///
- /// If [type] is a [TypeVariableType], this is a singleton list with
- /// the internal representation of the type held in that type variable.
- ///
- /// Otherwise the list is empty.
+ /// See the corresponding field on [TypeTest].
final List<Reference<Primitive>> typeArguments;
final Reference<Continuation> continuation;
« no previous file with comments | « pkg/compiler/lib/src/cps_ir/cps_ir_builder_task.dart ('k') | pkg/compiler/lib/src/cps_ir/type_propagation.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698