Skip to content

Commit b6deba5

Browse files
Fix --singlemethodname (#78207)
Single method compilation mode broke with the change to use System.CommandLine. "Not specified" no longer means `null`.
1 parent 0461372 commit b6deba5

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/coreclr/tools/aot/ILCompiler/Program.cs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -615,8 +615,7 @@ private MethodDesc CheckAndParseSingleMethodModeArguments(CompilerTypeSystemCont
615615
if (method == null)
616616
throw new CommandLineException($"Method '{singleMethodName}' not found in '{singleMethodTypeName}'");
617617

618-
if (method.HasInstantiation != (singleMethodGenericArgs != null) ||
619-
(method.HasInstantiation && (method.Instantiation.Length != singleMethodGenericArgs.Length)))
618+
if (method.Instantiation.Length != singleMethodGenericArgs.Length)
620619
{
621620
throw new CommandLineException(
622621
$"Expected {method.Instantiation.Length} generic arguments for method '{singleMethodName}' on type '{singleMethodTypeName}'");

0 commit comments

Comments
 (0)