Files
sdk/pkg/dev_compiler/test/codegen/names.dart
T
John Messerly af714fed80 fix for static methods and names banned in strict mode
* static methods qualified properly
* static method privacy is now enforced
* avoid static method names banned in strict mode
* avoid variable names banned in strict mode

We might want to relax privacy (for both instance and static), but for now it's nice and consistent with instance methods using ES6 Symbol

R=jacobr@google.com

Review URL: https://codereview.chromium.org/1034273003
2015-03-30 10:09:56 -07:00

27 lines
535 B
Dart

// 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.
var exports = 42;
class Foo {
_foo() => 123;
}
_foo() => 456;
class Frame {
final List arguments;
Frame.caller(this.arguments);
static callee() => null;
}
main() {
print(exports);
print(new Foo()._foo());
print(_foo());
print(new Frame.caller([1,2,3]));
var eval = Frame.callee;
print(eval);
}