From b71adda8b5f5046cf3db4fea603828bf7ec4a945 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Marjam=C3=A4ki?= Date: Sat, 6 Dec 2008 17:54:27 +0000 Subject: [PATCH] Minor optimisation. Don't do redundant checking --- CheckClass.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CheckClass.cpp b/CheckClass.cpp index fda3b41f1..396d96238 100644 --- a/CheckClass.cpp +++ b/CheckClass.cpp @@ -638,7 +638,7 @@ void CheckClass::virtualDestructor() // Find the destructor for the base class. const TOKEN *base = TOKEN::findmatch(_tokenizer->tokens(), "%any% ~ %var1% (", baseName); - while (base && TOKEN::Match(base, "::")) + while (TOKEN::Match(base, "::")) base = TOKEN::findmatch(base->next, "%any% ~ %var1% (", baseName); // Check that there is a destructor..