| Age | Commit message (Collapse) | Author | Lines |
|
|
|
Document the where keyword
Partial fix of #34601 (and last PR for it 🎉).
This documents the `where` keyword.
@rustbot modify labels: T-doc,C-enhancement
|
|
Document the ref keyword
Partial fix for #34601.
This documents the `ref` keyword with two examples, one failing to compile because the `ref` keyword is missing, and the same example fixed with the keyword inserted in the correct place.
It also explains (very *very* rapidly) the differences between `&` and `ref`.
I put a link to the best place I could find in the Reference but there may be something better that I didn't find.
|
|
to compile)
|
|
|
|
|
|
|
|
fix documentation surrounding the `in` and `for` keywords
Addresses #74529
The `in` keyword incorrectly referenced the `Iterator` trait. This reference was changed to `IntoIterator` without changing the underlying link.
Additionally, the `IntoIterator` trait was referenced towards the end of the documentation for `for`. An additional reference was added earlier and broadened the existing documentation from any iterator to anything that can be turned into an iterator.
|
|
Documentation for the false keyword
Partial fix of #34601.
Short documentation for the false keyword mainly pointing to the `true` keyword.
|
|
Clear up wording regarding the iterator and usage of `break`.
Co-authored-by: Josh Triplett <josh@joshtriplett.org>
|
|
|
|
|
|
|
|
Co-authored-by: Joshua Nelson <joshua@yottadb.com>
|
|
|
|
Document the trait keyword
Partial fix of #34601.
This document the trait keyword. To avoid doing too much and forcing more updates as functionalities evolve, I put two links to the reference, especially for trait objects. This mainly documents the "big" parts, not so much the small details that might trip someone experimenting.
@rustbot modify labels: T-doc,C-enhancement
|
|
consistent wording
|
|
Document the union keyword
Partial fix of #34601.
This documents the `union` keyword by presenting three cases: simply using a union, matching on a union and referencing the fields of a union.
@rustbot modify labels: T-doc,C-enhancement
|
|
|
|
Document the type keyword
Partial fix of #34601.
Two small examples, one clarifying that `type` only defines an alias, not a completely new type, the other explaining the use in traits.
@rustbot modify labels: T-doc,C-enhancement
|
|
Document the static keyword
Partial fix of #34601.
This documents the `static` keyword. It's basically a simplified version of the reference with more examples.
@rustbot modify labels: T-doc,C-enhancement
|
|
Co-authored-by: Josh Triplett <josh@joshtriplett.org>
|
|
|
|
|
|
|
|
|
|
|
|
Document the super keyword
Partial fix of #34601.
Quite short, just a small example and a link to the reference.
@rustbot modify labels: T-doc,C-enhancement
|
|
Document the Self keyword
Partial fix of #34601.
Document the `Self` keyword.
This contains simple examples of the places where `Self` can be used.
|
|
|
|
Document the return keyword
Partial fix of #34601.
This documents the `return` keyword with two short example to explain it is not needed for the last expression in a function and a long example to show its use when interrupting a function execution early.
I did not put a link to the reference since the only link I found was https://doc.rust-lang.org/stable/reference/expressions/return-expr.html#return-expressions.
@rustbot modify labels: T-doc,C-enhancement
|
|
Document the mut keyword
Partial fix for #34601.
Documentation for the `mut` keyword. I think it's okay for it to be quite short, this is not the book not the reference, but if you find something is missing, do not hesitate to tell me.
|
|
Document the mod keyword
Partial fix for #34601 .
Documentation for the `mod` keyword.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Apply suggestions from code review
Co-authored-by: Josh Triplett <josh@joshtriplett.org>
|
|
|
|
|
|
|
|
|
|
Fix suggestions from review.
Co-authored-by: Bastian Kauschke <bastian_kauschke@hotmail.de>
|
|
|
|
|
|
keyword docs for else and inkeyword docs for else and in.
First cut of else and in keyword docs. Comments and suggestions more than welcome.
|
|
|
|
Fixes #69298
|