mirror of
https://github.com/rust-lang/rust.git
synced 2026-04-27 18:57:42 +03:00
47d991a1aa
Use the term struct-like variant instead of anonymous structs for data of struct-like enum variants The current term in the docs `anonymous structs` seems to be outdated. I'd suggest `struct-like data` or rephrasing the whole sentence to use `struct-like variant`. The terminology used in the [Rust Book on enums](https://doc.rust-lang.org/stable/book/ch06-01-defining-an-enum.html#listing-6-2) is > named fields, like a struct The [Reference on enums](https://doc.rust-lang.org/stable/reference/items/enumerations.html#r-items.enum.constructor) uses > struct-like enum variant The term `anonymous struct` on the other hand is neither mentioned in the Rust book on [structs](https://doc.rust-lang.org/stable/book/ch05-01-defining-structs.html) or [enums](https://doc.rust-lang.org/stable/book/ch06-01-defining-an-enum.html#listing-6-2), nor the references on [structs](https://doc.rust-lang.org/stable/reference/items/structs.html) or [enums](https://doc.rust-lang.org/stable/reference/items/enumerations.html#r-items.enum.constructor).