@@ -1202,22 +1202,22 @@ declare module "vm" {
1202
1202
}
1203
1203
1204
1204
export class Script {
1205
- constructor ( code : string , options ?: ScriptOptions ) ;
1206
- runInContext ( contextifiedSandbox : Context , options ?: RunningScriptOptions ) : any ;
1207
- runInNewContext ( sandbox ?: Context , options ?: RunningScriptOptions ) : any ;
1208
- runInThisContext ( options ?: RunningScriptOptions ) : any ;
1205
+ constructor ( code : string , options ?: string | ScriptOptions ) ;
1206
+ runInContext ( contextifiedSandbox : Context , options ?: string | RunningScriptOptions ) : any ;
1207
+ runInNewContext ( sandbox ?: Context , options ?: string | RunningScriptOptions ) : any ;
1208
+ runInThisContext ( options ?: string | RunningScriptOptions ) : any ;
1209
1209
}
1210
1210
1211
1211
export function createContext ( sandbox ?: Context ) : Context ;
1212
1212
export function isContext ( sandbox : Context ) : boolean ;
1213
- export function runInContext ( code : string , contextifiedSandbox : Context , options ?: RunningScriptOptions ) : any ;
1213
+ export function runInContext ( code : string , contextifiedSandbox : Context , options ?: string | RunningScriptOptions ) : any ;
1214
1214
export function runInDebugContext ( code : string ) : any ;
1215
- export function runInNewContext ( code : string , sandbox ?: Context , options ?: RunningScriptOptions ) : any ;
1216
- export function runInThisContext ( code : string , options ?: RunningScriptOptions ) : any ;
1215
+ export function runInNewContext ( code : string , sandbox ?: Context , options ?: string | RunningScriptOptions ) : any ;
1216
+ export function runInThisContext ( code : string , options ?: string | RunningScriptOptions ) : any ;
1217
1217
/**
1218
1218
* @deprecated
1219
1219
*/
1220
- export function createScript ( code : string , filename ?: string ) : Script ;
1220
+ export function createScript ( code : string , options ?: string | ScriptOptions ) : Script ;
1221
1221
}
1222
1222
1223
1223
declare module "child_process" {
0 commit comments