djc / askama

Type-safe, compiled Jinja-like templates for Rust
Apache License 2.0
3.25k stars 213 forks source link

Remove instances of `use Enum::*` #1046

Closed Kijewski closed 2 months ago

Kijewski commented 2 months ago

It's an anti-pattern to arbitrarily import enum variant, because it hides typos (SpellingErrr => {} will still work), renamed and removed variants.

djc commented 2 months ago

Disagree that it's always an anti-pattern (and I think clippy lints against the bad cases), but these changes seem fine.