Chromium Code Reviews| Index: sdk/lib/_internal/compiler/implementation/ssa/js_names.dart |
| diff --git a/sdk/lib/_internal/compiler/implementation/ssa/js_names.dart b/sdk/lib/_internal/compiler/implementation/ssa/js_names.dart |
| index 4a4ae60ffd7d59bfacf76af3c0cf975bc0cdf943..0e88e10436ef05da17882abc06dadf24e306a76b 100644 |
| --- a/sdk/lib/_internal/compiler/implementation/ssa/js_names.dart |
| +++ b/sdk/lib/_internal/compiler/implementation/ssa/js_names.dart |
| @@ -155,7 +155,9 @@ class JsNames { |
| static const reservedPropertySymbols = |
| const <String>["__PROTO__", "prototype", "constructor"]; |
| + |
|
ahe
2012/12/17 16:23:25
Remove extra line.
|
| static Set<String> _reserved; |
| + static Set<String> _reservedNativeProperties; |
| static Set<String> get reserved { |
| if (_reserved == null) { |
| @@ -167,6 +169,16 @@ class JsNames { |
| return _reserved; |
| } |
| + static Set<String> get reservedNativeProperties { |
| + // TODO(sra): We need a complete list from the DOM. |
|
ahe
2012/12/17 16:23:25
Add two spaces of indentation.
|
| + if (_reservedNativeProperties == null) { |
| + const names = const <String>["x", "y", "z"]; |
|
ngeoffray
2012/12/18 12:34:03
What are those names in the DOM? Is this CL fixing
|
| + _reservedNativeProperties = new Set<String>(); |
|
ngeoffray
2012/12/18 12:34:03
You can use new Set<String>.from(names).
|
| + _reservedNativeProperties.addAll(names); |
| + } |
| + return _reservedNativeProperties; |
| + } |
| + |
| // TODO(ngeoffray): only the namer should call this method. |
| // Eventually move it there. |
| /* |