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

Side by Side Diff: tests/language/function_type3_test.dart

Issue 923113002: dart2js: fix dart2js crash when getRuntimeTypeArgument was not registered. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 5 years, 10 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 | Annotate | Revision Log
« no previous file with comments | « pkg/compiler/lib/src/js_backend/backend.dart ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 import "package:expect/expect.dart";
6
7 class A<T> {
8 @NoInlining()
9 A();
10
11 @NoInlining()
12 foo() => new B<T>();
13 }
14
15 class B<T> {
16 T bar() => null;
17 }
18
19 typedef F();
20 typedef F2(x);
21
22 // Dart2js realized that the generic type for A was not needed, but then used
23 // it nevertheless when it constructed the closure.
24 main() {
25 var f = new A<int>().foo().bar;
26 Expect.isTrue(f is F);
27 Expect.isFalse(f is F2);
28 }
OLDNEW
« no previous file with comments | « pkg/compiler/lib/src/js_backend/backend.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698