diff options
| author | Noah Lev <camelidcamel@gmail.com> | 2025-01-12 20:31:53 -0800 |
|---|---|---|
| committer | Noah Lev <camelidcamel@gmail.com> | 2025-01-13 00:39:00 -0800 |
| commit | f92b32c5f64ea900f2cd6936f648f407daee0d25 (patch) | |
| tree | 36489bbc911731106a581f2ad3e372541c009583 /src/librustdoc/clean/inline.rs | |
| parent | 5ccd6c04e5b0e81c8a0fdd8c0e9363be49ef053d (diff) | |
| download | rust-f92b32c5f64ea900f2cd6936f648f407daee0d25.tar.gz rust-f92b32c5f64ea900f2cd6936f648f407daee0d25.zip | |
rustdoc: Eliminate `AttributesExt`
The new code is more explicit and avoids trait magic that added needless complexity to this part of rustdoc.
Diffstat (limited to 'src/librustdoc/clean/inline.rs')
| -rw-r--r-- | src/librustdoc/clean/inline.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/librustdoc/clean/inline.rs b/src/librustdoc/clean/inline.rs index a17e0b1e4cc..3d51ab1967d 100644 --- a/src/librustdoc/clean/inline.rs +++ b/src/librustdoc/clean/inline.rs @@ -408,12 +408,12 @@ pub(crate) fn merge_attrs( } else { Attributes::from_hir(&both) }, - extract_cfg_from_attrs(&both[..], cx.tcx, &cx.cache.hidden_cfg), + extract_cfg_from_attrs(both.iter(), cx.tcx, &cx.cache.hidden_cfg), ) } else { ( Attributes::from_hir(old_attrs), - extract_cfg_from_attrs(&old_attrs[..], cx.tcx, &cx.cache.hidden_cfg), + extract_cfg_from_attrs(old_attrs.iter(), cx.tcx, &cx.cache.hidden_cfg), ) } } |
