From 618db6803d6c8b453abe6a1e92938ee20ac3aff6 Mon Sep 17 00:00:00 2001 From: Kadir Cetinkaya Date: Wed, 5 Aug 2020 21:14:31 +0200 Subject: [PATCH] [clangd][NFC] Delete dead code in ExtractFunction code action --- clang-tools-extra/clangd/refactor/tweaks/ExtractFunction.cpp | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/clang-tools-extra/clangd/refactor/tweaks/ExtractFunction.cpp b/clang-tools-extra/clangd/refactor/tweaks/ExtractFunction.cpp index dd62670..895afbb 100644 --- a/clang-tools-extra/clangd/refactor/tweaks/ExtractFunction.cpp +++ b/clang-tools-extra/clangd/refactor/tweaks/ExtractFunction.cpp @@ -480,17 +480,6 @@ CapturedZoneInfo captureZoneInfo(const ExtractionZone &ExtZone) { CurNumberOfSwitch += Increment; } - // Decrement CurNumberOf{NestedLoops,Switch} if statement is {Loop,Switch} - // and inside Extraction Zone. - void decrementLoopSwitchCounters(Stmt *S) { - if (CurrentLocation != ZoneRelative::Inside) - return; - if (isLoop(S)) - CurNumberOfNestedLoops--; - else if (isa(S)) - CurNumberOfSwitch--; - } - bool VisitDecl(Decl *D) { Info.createDeclInfo(D, CurrentLocation); return true; -- 2.7.4