Skip to content

Commit 7a45dd7

Browse files
authored
Merge pull request #5263 from bob-wilson/code-completion-failure
Use std::function to fix unsafe use of llvm::function_ref.
2 parents 785b4eb + dfa207b commit 7a45dd7

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/IDE/CodeCompletion.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -302,7 +302,7 @@ static bool shouldHideDeclFromCompletionResults(const ValueDecl *D) {
302302
return false;
303303
}
304304

305-
typedef llvm::function_ref<bool(ValueDecl*, DeclVisibilityKind)> DeclFilter;
305+
typedef std::function<bool(ValueDecl*, DeclVisibilityKind)> DeclFilter;
306306
DeclFilter DefaultFilter = [] (ValueDecl* VD, DeclVisibilityKind Kind) {return true;};
307307
DeclFilter KeyPathFilter = [](ValueDecl* decl, DeclVisibilityKind) -> bool {
308308
return isa<TypeDecl>(decl) ||

0 commit comments

Comments
 (0)