Skip to content

Conversation

mkrasnitski
Copy link

This removes the declarative macros parse_prefix_args! and parse_slash_args! that poise's command proc macro was deferring to in order to generate its argument parsing logic. Their functionality is now directly incorporated into the proc macro, which should make things much more readable and maintainable, and open the door for added features down the line. For example, the following changes are now much easier to add support for:

  • #[string] Option<T> and #[string] Vec<T>, which should bring #[string] parameters to full parity with standard parameters after PopArgument specialization was removed.
  • #[lazy] Vec<T>
  • Combining modifiers like #[lazy] #[string] Option<T>

Handle parsing slash arguments directly in the proc macro, for better
maintainability.
Handle parsing prefix arguments directly in the proc macro for better
maintainability.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants