CodeQL library for C#
codeql/csharp-all 0.5.1 (changelog, source)
Search

Member predicate ExtensionMethodCall::isOrdinaryStaticCall

Holds if this call is an ordinary static method call, where the target happens to be an extension method, for example the calls on lines 6 and 7 (but not line 5) in

static class Extensions {
  public static void Ext(int i) { }

  static void M(int i) {
    i.Ext();
    Ext(i);
    Extensions.Ext(i);
  }
}
predicate isOrdinaryStaticCall()