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

Side by Side Diff: tests/compiler/dart2js_extra/invalid_annotation2_test.dart

Issue 1257513002: dart2js: fix crash when annotations have syntax errors (fix #23983) (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years, 5 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 unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file.
4
5 // Regression test for http://dartbug.com/23893/
6 //
7 // Because annotations are parsed lazily, dart2js used to crash when an
8 // annotation had a syntax error.
9 // This checks the same behavior as invalid_annotation_test.dart, except that we
10 // use mirrors to trigger the error in the vm. This also triggers the error in
11 // dart2js differently.
12
13 @MirrorsUsed(targets: const [A])
14 import 'dart:mirrors';
15
16 @Deprecated("m"
17 , /// 01: compile-time error
18 )
19 class A {
20 }
21
22 main() {
23 reflectClass(A).metadata;
24 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698