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

Unified Diff: sdk/lib/_internal/compiler/implementation/types/value_type_mask.dart

Issue 694353007: Move dart2js from sdk/lib/_internal/compiler to pkg/compiler (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 1 month 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/types/value_type_mask.dart
diff --git a/sdk/lib/_internal/compiler/implementation/types/value_type_mask.dart b/sdk/lib/_internal/compiler/implementation/types/value_type_mask.dart
deleted file mode 100644
index 737be5e3a513e0e65e71bfbdddc8a275208e2a29..0000000000000000000000000000000000000000
--- a/sdk/lib/_internal/compiler/implementation/types/value_type_mask.dart
+++ /dev/null
@@ -1,49 +0,0 @@
-// Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file
-// for details. All rights reserved. Use of this source code is governed by a
-// BSD-style license that can be found in the LICENSE file.
-
-part of types;
-
-class ValueTypeMask extends ForwardingTypeMask {
- final TypeMask forwardTo;
- final value;
-
- ValueTypeMask(this.forwardTo, this.value);
-
- TypeMask nullable() {
- return isNullable
- ? this
- : new ValueTypeMask(forwardTo.nullable(), value);
- }
-
- TypeMask nonNullable() {
- return isNullable
- ? new ValueTypeMask(forwardTo.nonNullable(), value)
- : this;
- }
-
- bool get isValue => true;
-
- bool equalsDisregardNull(other) {
- if (other is! ValueTypeMask) return false;
- return super.equalsDisregardNull(other) && value == other.value;
- }
-
- TypeMask intersection(TypeMask other, ClassWorld classWorld) {
- TypeMask forwardIntersection = forwardTo.intersection(other, classWorld);
- if (forwardIntersection.isEmpty) return forwardIntersection;
- return forwardIntersection.isNullable
- ? nullable()
- : nonNullable();
- }
-
- bool operator==(other) => super == other;
-
- int get hashCode {
- return computeHashCode(value, isNullable, forwardTo);
- }
-
- String toString() {
- return 'Value mask: [$value] type: $forwardTo';
- }
-}

Powered by Google App Engine
This is Rietveld 408576698