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

Unified Diff: tests/language/compile_time_constant12_test.dart

Issue 581773002: Implement new constant expressions (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Address review 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
Index: tests/language/compile_time_constant12_test.dart
diff --git a/tests/language/unary_plus_negative_test.dart b/tests/language/compile_time_constant12_test.dart
similarity index 76%
copy from tests/language/unary_plus_negative_test.dart
copy to tests/language/compile_time_constant12_test.dart
index 9f68d8ad7eb089d5a2a39d45f6fefcf5c3f8b156..cbe1a817c2ed2d7e91be447f410f298f2827dd37 100644
--- a/tests/language/unary_plus_negative_test.dart
+++ b/tests/language/compile_time_constant12_test.dart
@@ -2,9 +2,11 @@
// 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.
-// There is no unary plus operator in Dart.
+const String s = "foo";
+const int i = s.length;
+
+use(x) => x;
main() {
- var a = 1;
- var b = +a;
+ use(i);
}

Powered by Google App Engine
This is Rietveld 408576698