Cysharp / ConsoleAppFramework

Zero Dependency, Zero Overhead, Zero Reflection, Zero Allocation, AOT Safe CLI Framework powered by C# Source Generator.
MIT License
1.66k stars 95 forks source link

"Index was outside the bounds of the array" when no value is provided #109

Closed xPaw closed 5 months ago

xPaw commented 5 months ago
ConsoleApp.Run(args, (int foo) => Console.WriteLine($"Foo: {foo}"));

Command: ./cmd --foo

This also makes me think the unchecked args[++i] would eat next argument.

For parameters that require a value, it should say so.

neuecc commented 5 months ago

thanks! I've fixed in v5.0.1!