Skip to content

Move Invoke* and Parse extension methods to their extended Symbol types #1905

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
Tracked by #1891
jonsequitur opened this issue Nov 2, 2022 · 2 comments
Closed
Tracked by #1891
Assignees
Labels
Milestone

Comments

@jonsequitur
Copy link
Contributor

jonsequitur commented Nov 2, 2022

    // All of these should be instance methods.
    public static class CommandExtensions 
    {
        public static int Invoke(this Command command, string[] args, IConsole console = null);
        public static int Invoke(this Command command, string commandLine, IConsole console = null);
        public static Task<int> InvokeAsync(this Command command, string[] args, IConsole console = null);
        public static Task<int> InvokeAsync(this Command command, string commandLine, IConsole console = null);
        // The comments from Argument(Extensions)::Parse also apply here.
        public static ParseResult Parse(this Command command, string[] args);
        public static ParseResult Parse(this Command command, string commandLine);
    }
@jonsequitur jonsequitur mentioned this issue Nov 2, 2022
56 tasks
@jonsequitur jonsequitur added this to the 2.0 GA milestone Nov 9, 2022
@KalleOlaviNiemitalo
Copy link

CommandExtensions.Parse was moved to Command.Parse in #2062.

CommandExtensions.Invoke and CommandExtensions.InvokeAsync have not been moved, nor did I find an open pull request for moving them.

@adamsitnik
Copy link
Member

#2106

fixed by #2106

@adamsitnik adamsitnik self-assigned this Mar 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants