diff options
Diffstat (limited to 'crates/ra_hir/src/lib.rs')
-rw-r--r-- | crates/ra_hir/src/lib.rs | 63 |
1 files changed, 0 insertions, 63 deletions
diff --git a/crates/ra_hir/src/lib.rs b/crates/ra_hir/src/lib.rs deleted file mode 100644 index b33293a18..000000000 --- a/crates/ra_hir/src/lib.rs +++ /dev/null | |||
@@ -1,63 +0,0 @@ | |||
1 | //! HIR (previously known as descriptors) provides a high-level object oriented | ||
2 | //! access to Rust code. | ||
3 | //! | ||
4 | //! The principal difference between HIR and syntax trees is that HIR is bound | ||
5 | //! to a particular crate instance. That is, it has cfg flags and features | ||
6 | //! applied. So, the relation between syntax and HIR is many-to-one. | ||
7 | //! | ||
8 | //! HIR is the public API of the all of the compiler logic above syntax trees. | ||
9 | //! It is written in "OO" style. Each type is self contained (as in, it knows it's | ||
10 | //! parents and full context). It should be "clean code". | ||
11 | //! | ||
12 | //! `ra_hir_*` crates are the implementation of the compiler logic. | ||
13 | //! They are written in "ECS" style, with relatively little abstractions. | ||
14 | //! Many types are not self-contained, and explicitly use local indexes, arenas, etc. | ||
15 | //! | ||
16 | //! `ra_hir` is what insulates the "we don't know how to actually write an incremental compiler" | ||
17 | //! from the ide with completions, hovers, etc. It is a (soft, internal) boundary: | ||
18 | //! https://www.tedinski.com/2018/02/06/system-boundaries.html. | ||
19 | |||
20 | #![recursion_limit = "512"] | ||
21 | |||
22 | mod semantics; | ||
23 | pub mod db; | ||
24 | mod source_analyzer; | ||
25 | |||
26 | pub mod diagnostics; | ||
27 | |||
28 | mod from_id; | ||
29 | mod code_model; | ||
30 | mod link_rewrite; | ||
31 | |||
32 | mod has_source; | ||
33 | |||
34 | pub use crate::{ | ||
35 | code_model::{ | ||
36 | Adt, AsAssocItem, AssocItem, AssocItemContainer, AttrDef, Callable, CallableKind, Const, | ||
37 | Crate, CrateDependency, DefWithBody, Docs, Enum, EnumVariant, Field, FieldSource, Function, | ||
38 | GenericDef, HasAttrs, HasVisibility, ImplDef, Local, MacroDef, Module, ModuleDef, ScopeDef, | ||
39 | Static, Struct, Trait, Type, TypeAlias, TypeParam, Union, VariantDef, Visibility, | ||
40 | }, | ||
41 | has_source::HasSource, | ||
42 | link_rewrite::resolve_doc_link, | ||
43 | semantics::{original_range, PathResolution, Semantics, SemanticsScope}, | ||
44 | }; | ||
45 | |||
46 | pub use hir_def::{ | ||
47 | adt::StructKind, | ||
48 | attr::Attrs, | ||
49 | body::scope::ExprScopes, | ||
50 | builtin_type::BuiltinType, | ||
51 | docs::Documentation, | ||
52 | item_scope::ItemInNs, | ||
53 | nameres::ModuleSource, | ||
54 | path::{ModPath, Path, PathKind}, | ||
55 | type_ref::Mutability, | ||
56 | }; | ||
57 | pub use hir_expand::{ | ||
58 | hygiene::Hygiene, | ||
59 | name::{AsName, Name}, | ||
60 | HirFileId, InFile, MacroCallId, MacroCallLoc, MacroDefId, /* FIXME */ | ||
61 | MacroFile, Origin, | ||
62 | }; | ||
63 | pub use hir_ty::display::HirDisplay; | ||