Skip to content

Commit

Permalink
Accept cl-style output arguments (/Fo, -Fo) for --fmodule-output
Browse files Browse the repository at this point in the history
- Edited condition to also accept `OPT__SLASH_Fo`, and `OPT__SLASH_Fo_COLON`
  • Loading branch information
sharadhr committed Dec 24, 2024
1 parent 51dee6b commit d8108f0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions clang/lib/Driver/Driver.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5442,7 +5442,7 @@ InputInfoList Driver::BuildJobsForAction(
InputInfoList Result = BuildJobsForActionNoCache(
C, A, TC, BoundArch, AtTopLevel, MultipleArchs, LinkingOutput,
CachedResults, TargetDeviceOffloadKind);
CachedResults[ActionTC] = Result;
CachedResults[ActionTC] = Result;
return Result;
}

Expand Down Expand Up @@ -5890,7 +5890,7 @@ const char *Driver::GetNamedOutputPath(Compilation &C, const JobAction &JA,
llvm::PrettyStackTraceString CrashInfo("Computing output path");
// Output to a user requested destination?
if (AtTopLevel && !isa<DsymutilJobAction>(JA) && !isa<VerifyJobAction>(JA)) {
if (Arg *FinalOutput = C.getArgs().getLastArg(options::OPT_o))
if (Arg *FinalOutput = C.getArgs().getLastArg(options::OPT_o, options::OPT__SLASH_Fo, options::OPT__SLASH_Fo_COLON))
return C.addResultFile(FinalOutput->getValue(), &JA);
}

Expand Down

0 comments on commit d8108f0

Please sign in to comment.