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

Unified Diff: pkg/compiler/lib/src/compile_time_constants.dart

Issue 792643003: Add DartTypes to abstract Types. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Rebased Created 6 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
« no previous file with comments | « no previous file | pkg/compiler/lib/src/compiler.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/compile_time_constants.dart
diff --git a/pkg/compiler/lib/src/compile_time_constants.dart b/pkg/compiler/lib/src/compile_time_constants.dart
index 11d56c963208cbab4ea692f841cc3e200f90de45..31eb5b3f8f5cbed50befbb0882e1530aba71553f 100644
--- a/pkg/compiler/lib/src/compile_time_constants.dart
+++ b/pkg/compiler/lib/src/compile_time_constants.dart
@@ -163,7 +163,7 @@ abstract class ConstantCompilerBase implements ConstantCompiler {
}
} else {
DartType constantType = value.value.getType(compiler.coreTypes);
- if (!constantSystem.isSubtype(compiler,
+ if (!constantSystem.isSubtype(compiler.types,
constantType, elementType)) {
if (isConst) {
compiler.reportFatalError(
@@ -910,7 +910,8 @@ class ConstructorEvaluator extends CompileTimeConstantEvaluator {
if (compiler.enableTypeAssertions) {
DartType elementType = element.type.substByContext(constructedType);
DartType constantType = constant.value.getType(compiler.coreTypes);
- if (!constantSystem.isSubtype(compiler, constantType, elementType)) {
+ if (!constantSystem.isSubtype(compiler.types,
+ constantType, elementType)) {
compiler.withCurrentElement(constant.element, () {
compiler.reportFatalError(
constant.node, MessageKind.NOT_ASSIGNABLE,
« no previous file with comments | « no previous file | pkg/compiler/lib/src/compiler.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698