Skip to content

Commit 8e8fc6a

Browse files
rakudramaCommit Queue
authored andcommitted
Partial revert "[rti/js_interop] Accelerate is JSObject"
This reverts one file from commit 2cc7d38. Change-Id: Iec4dc5e9a3e564b34ae326c5517e8d6764dfc9e1 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/425327 Reviewed-by: Srujan Gaddam <[email protected]> Commit-Queue: Stephen Adams <[email protected]>
1 parent 466cda2 commit 8e8fc6a

File tree

1 file changed

+1
-21
lines changed

1 file changed

+1
-21
lines changed

sdk/lib/_internal/js_shared/lib/rti.dart

Lines changed: 1 addition & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ import 'dart:_foreign_helper'
1818
RAW_DART_FUNCTION_REF,
1919
TYPE_REF;
2020
import 'dart:_interceptors'
21-
show JavaScriptFunction, JSArray, JSNull, JSUnmodifiableArray, JSObject;
21+
show JavaScriptFunction, JSArray, JSNull, JSUnmodifiableArray;
2222
import 'dart:_js_helper'
2323
as records
2424
show createRecordTypePredicate, getRtiForRecord;
@@ -1303,8 +1303,6 @@ Object? _simpleSpecializedIsTest(Rti testRti) {
13031303
isFn = RAW_DART_FUNCTION_REF(_isString);
13041304
} else if (_Utils.isIdentical(testRti, TYPE_REF<bool>())) {
13051305
isFn = RAW_DART_FUNCTION_REF(_isBool);
1306-
} else if (_Utils.isIdentical(testRti, TYPE_REF<JSObject>())) {
1307-
isFn = RAW_DART_FUNCTION_REF(_isJSObject);
13081306
}
13091307
return isFn;
13101308
}
@@ -1675,24 +1673,6 @@ String? _asStringQ(dynamic object) {
16751673
throw _TypeError.forType(object, 'String?');
16761674
}
16771675

1678-
bool _isJSObject(Object? object) {
1679-
if (object == null) return false;
1680-
if (JS('bool', 'typeof # == "object"', object)) {
1681-
if (_isDartObject(object)) return false;
1682-
return true;
1683-
}
1684-
if (JS('bool', 'typeof # == "function"', object)) {
1685-
if (JS_GET_FLAG('DEV_COMPILER')) {
1686-
// DDC functions have a signature attached.
1687-
var signatureName = JS_GET_NAME(JsGetName.SIGNATURE_NAME);
1688-
var signature = JS('', '#[#]', object, signatureName);
1689-
return signature == null;
1690-
}
1691-
return true;
1692-
}
1693-
return false;
1694-
}
1695-
16961676
String _rtiArrayToString(Object? array, List<String>? genericContext) {
16971677
String s = '', sep = '';
16981678
for (int i = 0; i < _Utils.arrayLength(array); i++) {

0 commit comments

Comments
 (0)