6244: Document awkward names r=matklad a=matklad

bors r+
🤖

Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
This commit is contained in:
bors[bot] 2020-10-15 16:14:54 +00:00 committed by GitHub
commit 1de2020109
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -403,6 +403,18 @@ Default names:
* `n_foo` -- number of foos
* `foo_idx` -- index of `foo`
Many names in rust-analyzer conflict with keywords.
We use mangled names instead of `r#ident` syntax:
```
struct -> strukt
crate -> krate
impl -> imp
trait -> trait_
fn -> func
enum -> enum_
mod -> module
```
## Early Returns