diff --git a/clang/lib/Index/USRGeneration.cpp b/clang/lib/Index/USRGeneration.cpp --- a/clang/lib/Index/USRGeneration.cpp +++ b/clang/lib/Index/USRGeneration.cpp @@ -262,6 +262,12 @@ // Mangle in type information for the arguments. for (auto *PD : D->parameters()) { + // FIXME: Make sure we don't have nullptrs in parameter lists of function + // decls. + if (!PD) { + IgnoreResults = true; + return; + } Out << '#'; VisitType(PD->getType()); }