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

Unified Diff: pkg/analyzer_cli/test/data/strong_example.dart

Issue 1459683003: `analyzer_cli` move to SDK. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: master merge Created 5 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
« no previous file with comments | « pkg/analyzer_cli/test/data/plugin_options.yaml ('k') | pkg/analyzer_cli/test/data/super_mixin_example.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analyzer_cli/test/data/strong_example.dart
diff --git a/pkg/analyzer_cli/test/data/strong_example.dart b/pkg/analyzer_cli/test/data/strong_example.dart
new file mode 100644
index 0000000000000000000000000000000000000000..2f332cd92ce72555e0a913fc5c135daa045d0ab7
--- /dev/null
+++ b/pkg/analyzer_cli/test/data/strong_example.dart
@@ -0,0 +1,18 @@
+// Copyright (c) 2015, 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.
+
+/// This produces an error with --strong enabled, but not otherwise.
+class MyIterable extends Iterable<String> {
+ // Error: invalid override
+ Iterator<Object> get iterator => [1, 2, 3].iterator;
+}
+
+main() {
+ var i = new MyIterable().iterator..moveNext();
+ print(i.current);
+
+ // Error: type check failed
+ List<String> list = <dynamic>[1, 2, 3];
+ print(list);
+}
« no previous file with comments | « pkg/analyzer_cli/test/data/plugin_options.yaml ('k') | pkg/analyzer_cli/test/data/super_mixin_example.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698