rust-lang / rust-lang/reference
Document all interesting/relevant zero cost abstractions
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 1.6k
- Forks
- 607
- PR merge metrics
- PR metrics pending
Description
I've been trying to research what zero cost abstractions Rust uses and I cannot find any meaningful info on anything other than iterators and generics. I've checked the main Rust repository, the Rust book and its repository, the reference and its repository, and even third party articles about Rust. I might just be stupid but there seems to be little if any concrete information on what is and is not zero cost
I think it would be very worthwhile to have a comprehensive list of (at least the interesting) zero cost abstractions (as well as when they don't apply) both to satisfy curiosity and to reassure people who come from languages where abstractions are punished
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing the Rust Reference and the linked Rust Book sections on iterators and generics, then compare the cases discussed in issue #80416. Define the scope of the comprehensive list and document which abstractions are zero cost and when that claim does not apply.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- documentation
- Issue type
- Documentation
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100