File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -511,11 +511,11 @@ Optional<CompilerInstance::ModuleBuffers> CompilerInstance::getInputBuffersIfPre
511
511
if (!serialization::isSerializedAST ((*inputFileOrErr)->getBuffer ()))
512
512
return ModuleBuffers (std::move (*inputFileOrErr));
513
513
514
- return ModuleBuffers (
515
- std::move (*inputFileOrErr),
516
- openModuleDoc (input). getValueOr ( nullptr ),
517
- openModuleSourceInfo (input). getValueOr ( nullptr )
518
- );
514
+ auto swiftdoc = openModuleDoc (input);
515
+ auto sourceinfo = openModuleSourceInfo (input);
516
+ return ModuleBuffers ( std::move (*inputFileOrErr ),
517
+ swiftdoc. hasValue () ? std::move (swiftdoc. getValue ()) : nullptr ,
518
+ sourceinfo. hasValue () ? std::move (sourceinfo. getValue ()) : nullptr );
519
519
}
520
520
521
521
Optional<std::unique_ptr<llvm::MemoryBuffer>>
You can’t perform that action at this time.
0 commit comments