diff options
| author | Camille GILLOT <gillot.camille@gmail.com> | 2020-11-27 00:27:34 +0100 |
|---|---|---|
| committer | Camille GILLOT <gillot.camille@gmail.com> | 2021-03-09 19:23:07 +0100 |
| commit | c298744da7208ebb37a76909eefdce2cc5698f79 (patch) | |
| tree | 75c9c57d6e57df9b95f4a301c7af6c97ac5ec67d /compiler/rustc_save_analysis/src | |
| parent | 3c0afc3e1c53042915d8626ae55919a64d462333 (diff) | |
| download | rust-c298744da7208ebb37a76909eefdce2cc5698f79.tar.gz rust-c298744da7208ebb37a76909eefdce2cc5698f79.zip | |
Remove hir::StructField::attrs.
Diffstat (limited to 'compiler/rustc_save_analysis/src')
| -rw-r--r-- | compiler/rustc_save_analysis/src/lib.rs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/compiler/rustc_save_analysis/src/lib.rs b/compiler/rustc_save_analysis/src/lib.rs index b3f281bcabc..2bd7aa58afa 100644 --- a/compiler/rustc_save_analysis/src/lib.rs +++ b/compiler/rustc_save_analysis/src/lib.rs @@ -387,6 +387,7 @@ impl<'tcx> SaveContext<'tcx> { let id = id_from_def_id(field_def_id); let span = self.span_from_span(field.ident.span); + let attrs = self.tcx.hir().attrs(field.hir_id); Some(Def { kind: DefKind::Field, @@ -398,9 +399,9 @@ impl<'tcx> SaveContext<'tcx> { parent: Some(id_from_def_id(scope_def_id)), children: vec![], decl_id: None, - docs: self.docs_for_attrs(&field.attrs), + docs: self.docs_for_attrs(attrs), sig: sig::field_signature(field, self), - attributes: lower_attributes(field.attrs.to_vec(), self), + attributes: lower_attributes(attrs.to_vec(), self), }) } |
