@@ -505,29 +505,29 @@ bool SymbolIndexImpl::foreachSymbolInFilePath(CanonicalFilePathRef filePath,
505
505
506
506
bool SymbolIndexImpl::foreachSymbolOccurrenceInFilePath (CanonicalFilePathRef filePath,
507
507
function_ref<bool (SymbolOccurrenceRef Occur)> Receiver) {
508
- bool didFinish = true ;
509
- ReadTransaction reader (DBase);
508
+ bool didFinish = true ;
509
+ ReadTransaction reader (DBase);
510
510
511
- IDCode filePathCode = reader.getFilePathCode (filePath);
512
- reader.foreachUnitContainingFile (filePathCode, [&](ArrayRef<IDCode> idCodes) -> bool {
513
- for (IDCode idCode : idCodes) {
514
- UnitInfo unitInfo = reader.getUnitInfo (idCode);
511
+ IDCode filePathCode = reader.getFilePathCode (filePath);
512
+ reader.foreachUnitContainingFile (filePathCode, [&](ArrayRef<IDCode> idCodes) -> bool {
513
+ for (IDCode idCode : idCodes) {
514
+ UnitInfo unitInfo = reader.getUnitInfo (idCode);
515
515
516
- for (UnitInfo::Provider provider : unitInfo.ProviderDepends ) {
517
- IDCode providerCode = provider.ProviderCode ;
518
- if (provider.FileCode == filePathCode) {
519
- auto record = createVisibleProviderForCode (providerCode, reader);
520
- didFinish = record->foreachSymbolOccurrence (Receiver);
516
+ for (UnitInfo::Provider provider : unitInfo.ProviderDepends ) {
517
+ IDCode providerCode = provider.ProviderCode ;
518
+ if (provider.FileCode == filePathCode) {
519
+ auto record = createVisibleProviderForCode (providerCode, reader);
520
+ didFinish = record->foreachSymbolOccurrence (Receiver);
521
521
522
- return false ;
523
- }
524
- }
522
+ return false ;
525
523
}
524
+ }
525
+ }
526
526
527
- return true ;
528
- });
527
+ return true ;
528
+ });
529
529
530
- return didFinish;
530
+ return didFinish;
531
531
}
532
532
533
533
bool SymbolIndexImpl::foreachCanonicalSymbolOccurrenceByKind (SymbolKind symKind, bool workspaceOnly,
0 commit comments