aboutsummaryrefslogtreecommitdiff
path: root/crates/hir_def/src
Commit message (Collapse)AuthorAgeFilesLines
* internal: refactor unresolved macro call diagnosticAleksey Kladov2021-06-131-31/+0
|
* internal: refactor unresolved import diagnosticAleksey Kladov2021-06-131-37/+0
|
* internal: refactor unresolved extern crate diagnosticAleksey Kladov2021-06-131-29/+0
|
* internal: start new diagnostics APIAleksey Kladov2021-06-131-14/+0
| | | | | | | | | | | | | | | | | | At the moment, this moves only a single diagnostic, but the idea is reafactor the rest to use the same pattern. We are going to have a single file per diagnostic. This file will define diagnostics code, rendering range and fixes, if any. It'll also have all of the tests. This is similar to how we deal with assists. After we refactor all diagnostics to follow this pattern, we'll probably move them to a new `ide_diagnostics` crate. Not that we intentionally want to test all diagnostics on this layer, despite the fact that they are generally emitted in the guts on the compiler. Diagnostics care to much about the end presentation details/fixes to be worth-while "unit" testing. So, we'll unit-test only the primary output of compilation process (types and name res tables), and will use integrated UI tests for diagnostics.
* internal: check that coverage marks are always pairedAleksey Kladov2021-06-131-5/+5
|
* cargo fmtMaan20032021-06-131-27/+24
|
* clippy::useless_returnMaan20032021-06-131-1/+1
|
* clippy::redundant_closureMaan20032021-06-131-2/+2
|
* clippy::clone_on_copyMaan20032021-06-132-2/+2
|
* clippy::useless_conversionMaan20032021-06-133-8/+5
|
* clippy::redudant_borrowMaan20032021-06-139-36/+36
|
* Don't stringify `cfg_attr`-gated attributesJonas Schievink2021-06-111-4/+18
| | | | This preserves the assigned `TokenId`s
* Reduce fst_path callsKirill Bulatov2021-06-101-11/+5
|
* Add more profiling for flyimportsKirill Bulatov2021-06-103-71/+85
|
* Implement dummy expansions for builtin attributesLukas Wirth2021-06-091-1/+3
|
* Merge #9169bors[bot]2021-06-074-3/+26
|\ | | | | | | | | | | | | | | | | | | 9169: internal: steps towards attribute macro token mapping r=jonas-schievink a=jonas-schievink This doesn't work yet, but we seem to be getting a bit further along (for example, we now stop highlighting `use` items inside item with attribute macros as if they were written verbatim). bors r+ Co-authored-by: Jonas Schievink <[email protected]>
| * Handle attribute macros in `descend_into_macros`Jonas Schievink2021-06-064-3/+26
| |
* | Make Documentation::new non-genericLaurențiu Nicola2021-06-071-2/+2
|/
* Render documentation for derive completionLukas Wirth2021-06-041-0/+4
|
* Return `ReachedFixedPoint::No` when resolving derive helperJonas Schievink2021-06-041-0/+1
|
* Update list of built-in attributesJonas Schievink2021-06-031-16/+22
|
* Make it opt-inJonas Schievink2021-06-033-1/+15
|
* Expand procedural attribute macrosJonas Schievink2021-06-032-6/+90
|
* NFC: remove redundant clones (clippy::perf)Matthias Krüger2021-06-031-1/+1
|
* ItemTree: make variant fields inherit the enum's visibilityJonas Schievink2021-06-032-4/+43
|
* Add commentJonas Schievink2021-06-031-0/+3
|
* Implement `#[rustc_skip_array_during_method_dispatch]`Jonas Schievink2021-06-011-1/+13
|
* Fall back to legacy preludeJonas Schievink2021-06-011-14/+27
|
* Implement per-edition preludesJonas Schievink2021-06-014-69/+186
|
* Expand fixme commentsDawer2021-05-311-1/+4
|
* Clean up, more docs.Dawer2021-05-311-4/+1
|
* Implement struct ctor applicationDawer2021-05-311-1/+1
|
* Merge #8866bors[bot]2021-05-311-2/+2
|\ | | | | | | | | | | | | | | 8866: Update salsa r=matklad a=jonas-schievink This updates salsa to include https://github.com/salsa-rs/salsa/pull/265, and removes all cancellation-related code from rust-analyzer Co-authored-by: Jonas Schievink <[email protected]>
| * Update salsaJonas Schievink2021-05-271-2/+2
| |
* | Diagnose unimplemented built-in macrosJonas Schievink2021-05-303-16/+48
| |
* | Thread proc-macro types through the HIRJonas Schievink2021-05-292-2/+17
| |
* | hir_ty: use async ret type for inference inside async bodiescynecx2021-05-294-3/+9
| |
* | Test that `ItemTree` works as intendedJonas Schievink2021-05-271-1/+73
| |
* | Don't store supertraits in ItemTreeLaurențiu Nicola2021-05-275-13/+3
|/
* Drop `ignore` from doctestsJonas Schievink2021-05-271-3/+3
|
* Reduce memory usage a bitJonas Schievink2021-05-262-9/+14
|
* Clean up ItemTree lowering now that it's 1:1Jonas Schievink2021-05-261-53/+26
|
* Stop expanding UseTrees during ItemTree loweringJonas Schievink2021-05-2610-168/+312
|
* Merge #8973bors[bot]2021-05-2512-621/+232
|\ | | | | | | | | | | | | | | 8973: internal: move diagnostics to hir r=matklad a=matklad Co-authored-by: Aleksey Kladov <[email protected]>
| * internal: move diagnostics to hirAleksey Kladov2021-05-2512-621/+232
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The idea here is to eventually get rid of `dyn Diagnostic` and `DiagnosticSink` infrastructure altogether, and just have a `enum hir::Diagnostic` instead. The problem with `dyn Diagnostic` is that it is defined in the lowest level of the stack (hir_expand), but is used by the highest level (ide). As a first step, we free hir_expand and hir_def from `dyn Diagnostic` and kick the can up to `hir_ty`, as an intermediate state. The plan is then to move DiagnosticSink similarly to the hir crate, and, as final third step, remove its usage from the ide. One currently unsolved problem is testing. You can notice that the test which checks precise diagnostic ranges, unresolved_import_in_use_tree, was moved to the ide layer. Logically, only IDE should have the infra to render a specific range. At the same time, the range is determined with the data produced in hir_def and hir crates, so this layering is rather unfortunate. Working on hir_def shouldn't require compiling `ide` for testing.
* | Consider trait to be in scope for trait-implLukas Wirth2021-05-251-13/+25
| |
* | Fix lowering of FnOnce() without return typeFlorian Diebold2021-05-251-12/+15
|/ | | | This should result in an implicit `-> ()`, not leaving out the binding.
* internal: intern `AttrInput`Jonas Schievink2021-05-243-13/+14
|
* Intern `GenericArgs`Jonas Schievink2021-05-244-11/+10
| | | | This shaves off another ~4 mb or so
* internal: intern `TypeBound`sJonas Schievink2021-05-249-25/+39
| | | | | Doesn't save much memory (~2 mb), but interning things is generally a good pattern to follow