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

Unified Diff: tests/language/src/PseudoKWIllegalTest.dart

Issue 9147006: fix issue 356 by making test match spec (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: rebased Created 8 years, 11 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/language/language.status ('k') | tests/language/src/PseudoKWNegativeTest.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/language/src/PseudoKWIllegalTest.dart
diff --git a/tests/language/src/PseudoKWIllegalTest.dart b/tests/language/src/PseudoKWIllegalTest.dart
new file mode 100644
index 0000000000000000000000000000000000000000..60ec6d60616fab4d0e93ce897f8802377f79ce56
--- /dev/null
+++ b/tests/language/src/PseudoKWIllegalTest.dart
@@ -0,0 +1,24 @@
+// Copyright (c) 2012, 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.
+// Check that we cannot use a pseudo keyword at the class level code.
+
+// Pseudo keywords are not allowed to be used as class names.
+class abstract { } /// 01: compile-time error
+class assert { } /// 02: compile-time error
+class call { } /// 03: compile-time error
+class Dynamic { } /// 04: compile-time error
+class factory { } /// 05: compile-time error
+class get { } /// 06: compile-time error
+class implements { } /// 07: compile-time error
+class import { } /// 08: compile-time error
+class interface { } /// 09: compile-time error
+class library { } /// 10: compile-time error
+class negate { } /// 11: compile-time error
+class operator { } /// 12: compile-time error
+class set { } /// 13: compile-time error
+class source { } /// 14: compile-time error
+class static { } /// 15: compile-time error
+class typedef { } /// 16: compile-time error
+
+main() { }
« no previous file with comments | « tests/language/language.status ('k') | tests/language/src/PseudoKWNegativeTest.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698