新增: - backend/venv/ - Python 虚拟环境 - backend/start.sh - 启动脚本(使用虚拟环境) - backend/requirements.txt - 依赖列表 - .gitignore - 忽略虚拟环境和缓存文件 说明: - 每个项目使用独立虚拟环境 - 避免依赖冲突 - 启动脚本自动创建和激活虚拟环境
27 lines
984 B
JavaScript
27 lines
984 B
JavaScript
import getPrototypeOf from "./getPrototypeOf.js";
|
|
import setPrototypeOf from "./setPrototypeOf.js";
|
|
import isNativeFunction from "./isNativeFunction.js";
|
|
import construct from "./construct.js";
|
|
function _wrapNativeSuper(t) {
|
|
var r = "function" == typeof Map ? new Map() : void 0;
|
|
return _wrapNativeSuper = function _wrapNativeSuper(t) {
|
|
if (null === t || !isNativeFunction(t)) return t;
|
|
if ("function" != typeof t) throw new TypeError("Super expression must either be null or a function");
|
|
if (void 0 !== r) {
|
|
if (r.has(t)) return r.get(t);
|
|
r.set(t, Wrapper);
|
|
}
|
|
function Wrapper() {
|
|
return construct(t, arguments, getPrototypeOf(this).constructor);
|
|
}
|
|
return Wrapper.prototype = Object.create(t.prototype, {
|
|
constructor: {
|
|
value: Wrapper,
|
|
enumerable: !1,
|
|
writable: !0,
|
|
configurable: !0
|
|
}
|
|
}), setPrototypeOf(Wrapper, t);
|
|
}, _wrapNativeSuper(t);
|
|
}
|
|
export { _wrapNativeSuper as default }; |