| 1177 | return Valdi::JSTypedArray(type, ptr, static_cast<size_t>(bytesLength), std::move(arrayBuffer)); |
| 1178 | } |
| 1179 | } |
| 1180 | |
| 1181 | Valdi::ValueType QuickJSJavaScriptContext::getValueType(const Valdi::JSValue& value) { |
| 1182 | auto guard = _threadAccessChecker.guard(); |
| 1183 | auto jsValue = fromValdiJSValue(value); |
| 1184 | |
| 1185 | if (JS_IsUndefined(jsValue) != 0) { |
| 1186 | return Valdi::ValueType::Undefined; |
| 1187 | } |
| 1188 | if (JS_IsNull(jsValue) != 0) { |
| 1189 | return Valdi::ValueType::Null; |
nothing calls this directly
no test coverage detected