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

Side by Side Diff: tests/html/json_helper.dart

Issue 1318043005: Support user generated custom native JS classes. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: ptal Created 5 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file 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 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. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 // Regression test for http://dartbug.com/22917 5 @JsName("JSON")
6 library json_helper;
6 7
7 import 'package:expect/expect.dart'; 8 // TODO(jacobr): depend on package:js instead of defining this annotation here.
sra1 2015/09/17 19:52:57 dart2js needs to find a known definition that is m
Siggi Cherem (dart-lang) 2015/09/18 20:34:10 how can package:js access this internal library? w
Jacob 2015/10/01 00:47:34 thanks for the link to what you did for lookup_map
Siggi Cherem (dart-lang) 2015/10/01 18:21:28 Makes sense you don't need to validate the version
Jacob 2015/10/02 20:08:15 got any pointers for how that should be done? Ther
9 class JsName {
10 const JsName([this.name]);
11 final String name;
12 }
8 13
9 m(x) => print('x: $x'); 14 external String stringify(object);
10
11 test() => Function.apply(m, []);
12
13 main() {
14 Expect.throws(test);
15 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698