Files
sdk/pkg/compiler
Stephen Adams 77483ae5d3 dart2js: Forbid # placeholders in JS function bodies.
This enforces one of the guidelines that is described in the documentation for 'JS' in js_runtime/lib/foreign_helper.dart

The JS code should be rewritten to explicitly capture the values in JS.

    // Dart 'a' might change after it is closed over.
    JS('', 'function(){return #;}', a);

-->

    // Immediately bind Dart 'a' to JS 'a' and then close over JS 'a':
    //
    JS('', '(function(a){return function(){return a;};})(#)', a);

R=sigmund@google.com

Review URL: https://codereview.chromium.org/1436263002 .
2015-11-12 15:38:12 -08:00
..
2015-11-02 14:43:22 +01:00
2015-10-05 10:20:36 -07:00