Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Suppress clippy should_implement_trait lint
I think there is no ambiguity in from_str as a method name so "choose a less ambiguous method name" is unnecessary, and it can't be a FromStr impl in this case because FromStr's error type cannot borrow from the input string slice. warning: method `from_str` can be confused for the standard trait method `std::str::FromStr::from_str` --> serde_derive_internals/src/case.rs:50:5 | 50 | / pub fn from_str(rename_all_str: &str) -> Result<Self, ParseError> { 51 | | for (name, rule) in RENAME_RULES { 52 | | if rename_all_str == *name { 53 | | return Ok(*rule); ... | 58 | | }) 59 | | } | |_____^ | = note: `#[warn(clippy::should_implement_trait)]` on by default = help: consider implementing the trait `std::str::FromStr` or choosing a less ambiguous method name = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#should_implement_trait
- Loading branch information