forked from OSchip/llvm-project
[test][clangd] Fix use-after-return after 72142fbac4
This commit is contained in:
parent
cbb3a39e4d
commit
dde62a575a
|
@ -1227,12 +1227,15 @@ TEST_F(TUSchedulerTests, IncluderCache) {
|
|||
auto GetFlags = [&](PathRef Header) {
|
||||
S.update(Header, getInputs(Header, ";"), WantDiagnostics::Yes);
|
||||
EXPECT_TRUE(S.blockUntilIdle(timeoutSeconds(10)));
|
||||
Notification CmdDone;
|
||||
tooling::CompileCommand Cmd;
|
||||
S.runWithPreamble("GetFlags", Header, TUScheduler::StaleOrAbsent,
|
||||
[&](llvm::Expected<InputsAndPreamble> Inputs) {
|
||||
ASSERT_FALSE(!Inputs) << Inputs.takeError();
|
||||
Cmd = std::move(Inputs->Command);
|
||||
CmdDone.notify();
|
||||
});
|
||||
CmdDone.wait();
|
||||
EXPECT_TRUE(S.blockUntilIdle(timeoutSeconds(10)));
|
||||
return Cmd.CommandLine;
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue