Skip to content

Commit 49cd50d

Browse files
Chris LattnerChris Lattner
authored andcommitted
remove a fallback algorithm that is not necessary anymore.
1 parent a06cacb commit 49cd50d

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

lib/AST/DiagnosticEngine.cpp

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -502,12 +502,6 @@ void DiagnosticEngine::emitDiagnostic(const Diagnostic &diagnostic) {
502502
// If a declaration was provided instead of a location, and that declaration
503503
// has a location we can point to, use that location.
504504
loc = decl->getLoc();
505-
// With an implicit parameter try to point to its type.
506-
if (loc.isInvalid() && isa<ParamDecl>(decl)) {
507-
if (auto Pat =
508-
cast<ParamDecl>(decl)->getParamParentPattern())
509-
loc = Pat->getLoc();
510-
}
511505

512506
if (loc.isInvalid()) {
513507
// There is no location we can point to. Pretty-print the declaration

0 commit comments

Comments
 (0)