Index: tool/input_sdk/private/ddc_runtime/classes.dart |
diff --git a/tool/input_sdk/private/ddc_runtime/classes.dart b/tool/input_sdk/private/ddc_runtime/classes.dart |
index 683aed56ea36990f5418c19bf7777b1c0d4b9fed..adaf1d984f98c1c594bceb7043266b41b401e324 100644 |
--- a/tool/input_sdk/private/ddc_runtime/classes.dart |
+++ b/tool/input_sdk/private/ddc_runtime/classes.dart |
@@ -230,27 +230,6 @@ setSignature(f, signature) => JS('', '''(() => { |
hasMethod(obj, name) => JS('', '$getMethodType($obj, $name) !== void 0'); |
/// |
-/// This is called whenever a derived class needs to introduce a new field, |
-/// shadowing a field or getter/setter pair on its parent. |
-/// |
-/// This is important because otherwise, trying to read or write the field |
-/// would end up calling the getter or setter, and one of those might not even |
-/// exist, resulting in a runtime error. Even if they did exist, that's the |
-/// wrong behavior if a new field was declared. |
-/// |
-virtualField(subclass, fieldName) => JS('', '''(() => { |
- // If the field is already overridden, do nothing. |
- let prop = $getOwnPropertyDescriptor($subclass.prototype, $fieldName); |
- if (prop) return; |
- |
- let symbol = Symbol($subclass.name + '.' + $fieldName.toString()); |
- $defineProperty($subclass.prototype, $fieldName, { |
- get: function() { return this[symbol]; }, |
- set: function(x) { this[symbol] = x; } |
- }); |
-})()'''); |
- |
-/// |
/// Given a class and an initializer method name, creates a constructor |
/// function with the same name. For example `new SomeClass.name(args)`. |
/// |