4 ms·
Rust doesn't enforce style anywhere. You can turn off all style warnings at once too with `#![allow(bad_style)]` or a command line flag. By default it just war
by Manishearth 11y ago
Rust doesn't enforce style anywhere. You can turn off all style warnings at once too with `#![allow(bad_style)]` or a command line flag.
By default it just warns. That's not enforcing.
- andresmanz 11y agoCome on, even that flag's name is ridiculous. They basically say, for example, that writing camel case, which is the preferred style in most of the projects I've seen, is bad style. Do they like being unnecessarily antipathetic? People think about their personal preferred style for years, and they have very good reasons for choosing them. And in _many_ cases, it's exactly the style that's called bad by Rust's creators. How about making it the opposite, '#![allow(default_style)]'? Or at least '#![allow(non_default_style)]'?
- Manishearth 11y agoIn some cases skirting style can be harmful (e.g. in match statements there's an ambiguity with enum variants and variable bindings that is not an issue because of the style lints). But I get your point. I think people would be open to that naming change if you file an issue.
- andresmanz 11y agoYes, you're right, of course. Maybe I could at least try, yes. I mean... It's kind of silly, I know, but that would already change the way I look at Rust.