![]() If someone wants to have identifiers highlighted based on details about their definitions, they should use syntax highlighting based on the definition information provided by Rust Analyzer. When I move the definition out of the function body so it can be shared with another function, this requires changing from let to const, which for no meaningful reason requires me to rename all references to this data to scream at you in uppercase. (For those new to Rust, keep in mind that both let and const are constant, unlike let mut.) I want it to be named the same in either case. When I refer to some data, I really don't care whether this data was defined as let n: u8 = 42 or const n: u8 = 42. The distinctions that are expressed through the choice of naming convention don't even make sense: ![]() If you choose to violate the naming conventions, you have my sympathy. ![]() I'm tempted to do the same for enum variants. I would love to have an option #! to help maintain consistency. I've eventually had enough, and now I start every crate with #!. ![]() ![]() And this is one of extremely few things in common Rust style that I find disturbing at all. I find the incoherent mess of naming conventions slightly disturbing. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |