MCPcopy
hub / github.com/compiler-explorer/compiler-explorer / makeCompilationEnvironment

Function makeCompilationEnvironment

test/utils.ts:69–74  ·  view source on GitHub ↗
(options: Record<string, any>)

Source from the content-addressed store, hash-verified

67
68// TODO: Find proper type for options
69export function makeCompilationEnvironment(options: Record<string, any>): CompilationEnvironment {
70 ensureTempCleanup();
71 const compilerProps = new CompilerProps(options.languages, fakeProps(options.props || {}));
72 const compilationQueue = options.queue || new CompilationQueue(options.concurrency || 1, options.timeout, 100_000);
73 return new CompilationEnvironment(compilerProps, fakeProps({}), compilationQueue, options.doCache);
74}
75
76export function makeFakeCompilerInfo(props: Partial<CompilerInfo>): CompilerInfo {
77 return props as CompilerInfo;

Callers 15

createCompilerFunction · 0.85
android-tests.tsFile · 0.85
objdumper-tests.tsFile · 0.85
library-tests.tsFile · 0.85
odin-tests.tsFile · 0.85
pascal-tests.tsFile · 0.85
clojure-tests.tsFile · 0.85
d-tests.tsFile · 0.85
win-path-tests.tsFile · 0.85
createCompilerFunction · 0.85
resolc-tests.tsFile · 0.85
nim-tests.tsFile · 0.85

Calls 2

ensureTempCleanupFunction · 0.85
fakePropsFunction · 0.85

Tested by

no test coverage detected