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

Unified Diff: tests/compiler/dart2js/metadata_test.dart

Issue 574683002: Use ConstExp for storing constants. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Updated cf. comments. Created 6 years, 3 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
« no previous file with comments | « tests/compiler/dart2js/const_exp_test.dart ('k') | tests/compiler/dart2js/mirrors_used_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/compiler/dart2js/metadata_test.dart
diff --git a/tests/compiler/dart2js/metadata_test.dart b/tests/compiler/dart2js/metadata_test.dart
index 903cbeec3125da51a2a28f1131121420a9caab86..12022f7428c192885c21ffdf754c54b256c1884b 100644
--- a/tests/compiler/dart2js/metadata_test.dart
+++ b/tests/compiler/dart2js/metadata_test.dart
@@ -36,7 +36,7 @@ void checkAnnotation(String name, String declaration,
'Unexpected metadata count on $element.');
PartialMetadataAnnotation annotation = element.metadata.head;
annotation.ensureResolved(compiler);
- PrimitiveConstant value = annotation.value;
+ PrimitiveConstant value = annotation.constant.value;
Expect.stringEquals('xyz', value.value.slowToString());
checkPosition(annotation, annotation.cachedNode, source1, compiler);
@@ -59,8 +59,8 @@ void checkAnnotation(String name, String declaration,
Expect.isFalse(identical(annotation1, annotation2),
'expected unique instances');
Expect.notEquals(annotation1, annotation2, 'expected unequal instances');
- PrimitiveConstant value1 = annotation1.value;
- PrimitiveConstant value2 = annotation2.value;
+ PrimitiveConstant value1 = annotation1.constant.value;
+ PrimitiveConstant value2 = annotation2.constant.value;
Expect.identical(value1, value2, 'expected same compile-time constant');
Expect.stringEquals('xyz', value1.value.slowToString());
Expect.stringEquals('xyz', value2.value.slowToString());
@@ -89,7 +89,7 @@ void checkAnnotation(String name, String declaration,
Expect.equals(1, length(element.metadata));
PartialMetadataAnnotation annotation = element.metadata.head;
annotation.ensureResolved(compiler);
- PrimitiveConstant value = annotation.value;
+ PrimitiveConstant value = annotation.constant.value;
Expect.stringEquals('xyz', value.value.slowToString());
checkPosition(annotation, annotation.cachedNode, source3, compiler);
@@ -118,8 +118,8 @@ void checkAnnotation(String name, String declaration,
Expect.isFalse(identical(annotation1, annotation2),
'expected unique instances');
Expect.notEquals(annotation1, annotation2, 'expected unequal instances');
- PrimitiveConstant value1 = annotation1.value;
- PrimitiveConstant value2 = annotation2.value;
+ PrimitiveConstant value1 = annotation1.constant.value;
+ PrimitiveConstant value2 = annotation2.constant.value;
Expect.identical(value1, value2, 'expected same compile-time constant');
Expect.stringEquals('xyz', value1.value.slowToString());
Expect.stringEquals('xyz', value2.value.slowToString());
@@ -171,7 +171,7 @@ void testLibraryTags() {
PartialMetadataAnnotation annotation = metadata.head;
annotation.ensureResolved(compiler);
- PrimitiveConstant value = annotation.value;
+ PrimitiveConstant value = annotation.constant.value;
Expect.stringEquals('xyz', value.value.slowToString());
checkPosition(annotation, annotation.cachedNode, source, compiler);
« no previous file with comments | « tests/compiler/dart2js/const_exp_test.dart ('k') | tests/compiler/dart2js/mirrors_used_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698