From e15266388ec5faaafa92dcd1096d3a438e990c65 Mon Sep 17 00:00:00 2001 From: Anders Schack-Mulligen Date: Thu, 18 Sep 2025 10:30:40 +0200 Subject: [PATCH] C#: Fix bogus guards implication. --- csharp/ql/lib/semmle/code/csharp/controlflow/Guards.qll | 4 ---- 1 file changed, 4 deletions(-) diff --git a/csharp/ql/lib/semmle/code/csharp/controlflow/Guards.qll b/csharp/ql/lib/semmle/code/csharp/controlflow/Guards.qll index 7185e39a45b2..6f8856e1978a 100644 --- a/csharp/ql/lib/semmle/code/csharp/controlflow/Guards.qll +++ b/csharp/ql/lib/semmle/code/csharp/controlflow/Guards.qll @@ -1620,10 +1620,6 @@ module Internal { isGuard(g1, v1) and v2 = v1 or - g2 = g1.(Assignment).getLValue() and - isGuard(g1, v1) and - v2 = v1 - or g2 = g1.(CastExpr).getExpr() and isGuard(g1, v1) and v2 = v1.(NullValue)