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

Method buildExecutable

lib/compilers/rust.ts:330–342  ·  view source on GitHub ↗
(
        compiler: string,
        options: string[],
        inputFilename: string,
        execOptions: ExecutionOptionsWithEnv,
    )

Source from the content-addressed store, hash-verified

328 }
329
330 override buildExecutable(
331 compiler: string,
332 options: string[],
333 inputFilename: string,
334 execOptions: ExecutionOptionsWithEnv,
335 ) {
336 // bug #5630: in presence of `--emit mir=..` rustc does not produce an executable.
337 const newOptions = options.filter(
338 (opt, idx, allOpts) =>
339 !(opt === '--emit' && allOpts[idx + 1].startsWith('mir=')) && !opt.startsWith('mir='),
340 );
341 return super.runCompiler(compiler, newOptions, inputFilename, execOptions);
342 }
343
344 override isOutputLikelyLlvmIr(options: string[]): boolean {
345 const emitIndex = options.indexOf('--emit');

Callers

nothing calls this directly

Calls 1

runCompilerMethod · 0.45

Tested by

no test coverage detected