rust-analyzer/crates/ra_hir/src
bors[bot] 14e19c0df1
Merge #2179
2179: Use HirDatabase to compute `is_deprecated` r=matklad a=martskins

This PR fixes #2167 by introducing `attributes_query` and adding `fn attrs(&self, def: crate::AttrDef) -> Option<Arc<[Attr]>>;`  to the `DefDatabase` trait.

I'm a little concerned about the two spots in `attributes_query` where code is repeated, but I couldn't figure out a way to avoid that, so.. I welcome suggestions 😄 



Co-authored-by: Martin Asquino <martin.asquino@gmail.com>
2019-11-06 21:11:42 +00:00
..
code_model HirDatabase stored attributes 2019-11-04 18:16:35 -03:00
expr Rename MockDatabase -> TestDB 2019-11-04 22:21:15 +03:00
ty Move Namespace enum closer to usage 2019-11-04 23:02:35 +03:00
adt.rs move struct & enum data to hir_def 2019-10-31 16:40:36 +03:00
code_model.rs Merge #2179 2019-11-06 21:11:42 +00:00
db.rs Merge #2179 2019-11-06 21:11:42 +00:00
debug.rs cleanup 2019-10-29 16:19:08 +03:00
diagnostics.rs Move CrateDefMap to hir_def 2019-11-03 18:04:06 +03:00
expr.rs remove forward pointer for type_ref 2019-10-30 17:43:14 +03:00
from_id.rs Add small module-level docs 2019-11-04 00:23:14 +03:00
from_source.rs Move CrateDefMap to hir_def 2019-11-03 18:04:06 +03:00
generics.rs Refactor to unify with method resolution 2019-11-01 19:57:08 +01:00
ids.rs Move ids to hir_def crate 2019-10-30 13:11:38 +03:00
impl_block.rs move hygiene to hir_expand 2019-10-30 19:10:53 +03:00
lang_item.rs introduce ra_hir_def 2019-10-30 12:27:54 +03:00
lib.rs Merge #2179 2019-11-06 21:11:42 +00:00
marks.rs Cleanup unused marks 2019-11-04 13:29:07 +03:00
resolve.rs Remove last traces of nameres from hir 2019-11-03 23:49:44 +03:00
source_binder.rs Move CrateDefMap to hir_def 2019-11-03 18:04:06 +03:00
test_db.rs Appease the linter by dummy doc comments 2019-11-04 22:33:21 +03:00
traits.rs push name down to hir_expand 2019-10-30 18:56:20 +03:00
ty.rs Move Namespace enum closer to usage 2019-11-04 23:02:35 +03:00
type_alias.rs push name down to hir_expand 2019-10-30 18:56:20 +03:00
util.rs make_mut_slice 2019-10-14 19:50:12 +09:00