Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
check if expectation can be fulfilled in `check_unsafe_derive_deseria…
…lize` This commit adds fulfilling expectations to `check_unsafe_derive_deserialize`. The utility function `clippy_utils::fulfill_or_allowed` is not used because using it would require to move the check for allowed after the check iterating over all inherent impls of the type, doing possibly unnecessary work. Instead, `is_lint_allowed` is called as before, but additionally, once certain that the lint should be emitted, expectations are checked and fulfilled if found. In that case actually emitting the lint is skipped. fixes: rust-lang#12802 changelog: fulfill expectations in `check_unsafe_derive_deserialize`
- Loading branch information