Skip to content

Commit 6269ab1

Browse files
committed
Auto merge of #8881 - dmarcoux:update-outdated-doc, r=llogiq
Fix imports for "Checking if a type defines a specific method" The import of `clippy_utils::is_type_diagnostic_item` would cause this error: ``` error[E0432]: unresolved import `clippy_utils::is_type_diagnostic_item ``` changelog: none
2 parents fbb9e56 + 21d9493 commit 6269ab1

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

doc/common_tools_writing_lints.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,8 @@ A list of defined paths for Clippy can be found in [paths.rs][paths]
159159
To check if our type defines a method called `some_method`:
160160

161161
```rust
162-
use clippy_utils::{is_type_diagnostic_item, return_ty};
162+
use clippy_utils::ty::is_type_diagnostic_item;
163+
use clippy_utils::return_ty;
163164

164165
impl<'tcx> LateLintPass<'tcx> for MyTypeImpl {
165166
fn check_impl_item(&mut self, cx: &LateContext<'tcx>, impl_item: &'tcx ImplItem<'_>) {

0 commit comments

Comments
 (0)