rust-lang / rust-lang/libc

Mark all structs `non_exhaustive` for 1.0

Open
#4,080 13 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Rust
Stars
2.6k
Forks
1.3k
Avg merge
1d 22h
Merged PRs (30d)
69

Description

There are a handful of structs that users should be able to access but possibly not construct in case fields change in the future. Currently we often do this by having a single private field, but maybe #[non_exhaustive] would be better suited here.

Contributor guide

Open the contributing guide

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

No files, tests, or entry points are named. Start by inventorying the structs currently using private fields, then assess which should be marked non_exhaustive and verify the compatibility implications for 1.0; done requires an agreed, complete set of structs and migration approach.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
operating-systems
Issue type
Refactor
Difficulty
5/5
Estimated time
Over a week
Activity status
Quiet
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.