Merge pull request #11624 from jcogs33/jcogs33/exclude-paramless-constructors-from-dataflowtargetapi

Java/C#: exclude parameterless constructors from `DataFlowTargetApi`
This commit is contained in:
Jami
2022-12-13 10:05:57 -05:00
committed by GitHub
6 changed files with 22 additions and 20 deletions

View File

@@ -358,6 +358,9 @@ class Constructor extends DotNet::Constructor, Callable, Member, Attributable, @
if this.isStatic() then result = this.getParameter(i) else result = this.getParameter(i - 1)
}
/** Holds if this is a constructor without parameters. */
predicate isParameterless() { this.getNumberOfParameters() = 0 }
override string getUndecoratedName() { result = ".ctor" }
}