mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
[sourcekit] Fix assertion hit when doing cursor-info on a subscript parameter declaration.
Fixes rdar:/30060622
This commit is contained in:
@@ -454,6 +454,9 @@ void walkRelatedDecls(const ValueDecl *VD, const FnTy &Fn) {
|
||||
++NamesSeen[VD->getFullName()];
|
||||
SmallVector<ValueDecl *, 8> RelatedDecls;
|
||||
|
||||
if (isa<ParamDecl>(VD))
|
||||
return; // Parameters don't have interesting related declarations.
|
||||
|
||||
// FIXME: Extract useful related declarations, overloaded functions,
|
||||
// if VD is an initializer, we should extract other initializers etc.
|
||||
// For now we use UnqualifiedLookup to fetch other declarations with the same
|
||||
|
||||
Reference in New Issue
Block a user