rust-lang / rust-lang/getopts

Mark public enums non-exhaustive

Open
#136 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Rust
Stars
250
Forks
69
PR merge metrics
No merged PRs in 30d

Description

Fail, Occur, and ParsingStyle could all have legitimate reasons to gain options in the future, so for 0.3 we should mark them #[non_exhaustive].

It may also be worth doing some renaming to make things more consistent with the rest of the ecosystem:

  • Fail -> Error
  • Occur::Req -> Required
  • Occur::Multi -> Occur::ZeroOrMore

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Locate the public definitions of the Fail, Occur, and ParsingStyle enums and inspect how their variants are used across the crate. Mark the three enums non-exhaustive, then determine whether the proposed renames are in scope and verify that the public API and existing tests still build.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
cli
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.