Update model editor C# query to return method parameters with parentheses
This commit is contained in:
@@ -51,13 +51,6 @@ export function decodeBqrsToMethods(
|
||||
classification = CallClassification.Unknown;
|
||||
}
|
||||
|
||||
if (!methodParameters.startsWith("(")) {
|
||||
// There's a difference in how the Java and C# queries return method parameters. In the C# query, the method
|
||||
// parameters are returned without parentheses. In the Java query, the method parameters are returned with
|
||||
// parentheses. Therefore, we'll just add them if we don't see them.
|
||||
methodParameters = `(${methodParameters})`;
|
||||
}
|
||||
|
||||
const signature = `${packageName}.${typeName}#${methodName}${methodParameters}`;
|
||||
|
||||
// For Java, we'll always get back a .jar file, and the library version may be bad because not all library authors
|
||||
|
||||
@@ -146,7 +146,7 @@ class Endpoint extends Callable {
|
||||
* Gets the parameter types of this endpoint.
|
||||
*/
|
||||
bindingset[this]
|
||||
string getParameterTypes() { result = parameterQualifiedTypeNamesToString(this) }
|
||||
string getParameterTypes() { result = "(" + parameterQualifiedTypeNamesToString(this) + ")" }
|
||||
|
||||
private string getDllName() { result = this.getLocation().(Assembly).getName() }
|
||||
|
||||
|
||||
@@ -583,7 +583,7 @@ describe("decodeBqrsToMethods", () => {
|
||||
"System.Reflection",
|
||||
"RuntimeReflectionExtensions",
|
||||
"GetMethodInfo",
|
||||
"System.Delegate",
|
||||
"(System.Delegate)",
|
||||
true,
|
||||
"mscorlib",
|
||||
"4.0.0.0",
|
||||
@@ -651,7 +651,7 @@ describe("decodeBqrsToMethods", () => {
|
||||
"Moq",
|
||||
"Times",
|
||||
"Validate",
|
||||
"System.Int32",
|
||||
"(System.Int32)",
|
||||
false,
|
||||
"Times.cs",
|
||||
"",
|
||||
|
||||
Reference in New Issue
Block a user