some minor restructuring
This commit is contained in:
@@ -72,7 +72,7 @@ export interface BufferPrimordials {
|
||||
export interface FunctionPrimordials {
|
||||
invokeType(args: IArguments, self: any): "new" | "call";
|
||||
invokeTypeInfer(): "new" | "call";
|
||||
target(): Function | null | undefined;
|
||||
target(level?: number): Function | null | undefined;
|
||||
setConstructable(func: Function, flag: boolean): void;
|
||||
setCallable(func: Function, flag: boolean): void;
|
||||
invoke(func: Function, self: any, args: any[]): any;
|
||||
|
||||
@@ -58,6 +58,10 @@ export const Function = (() => {
|
||||
public static compile(src: string, filename?: string) {
|
||||
return compile(String(src), filename);
|
||||
}
|
||||
|
||||
public static newTarget() {
|
||||
return func.target(1);
|
||||
}
|
||||
}
|
||||
|
||||
func.setCallable(Function, true);
|
||||
|
||||
Reference in New Issue
Block a user