aboutsummaryrefslogtreecommitdiff
path: root/crates/ide/src/goto_definition.rs
Commit message (Collapse)AuthorAgeFilesLines
* Factor out `pick_best_token` ide pattern into `ide_db`Lukas Wirth2021-06-221-15/+8
|
* internal: don't #[ignore] testsAleksey Kladov2021-06-151-5/+5
| | | | See the style.md for motivation
* internal: check diagnostics in all files and not just the first oneAleksey Kladov2021-06-131-6/+6
|
* clippy::clone_on_copyMaan20032021-06-131-1/+1
|
* clippy::redudant_borrowMaan20032021-06-131-1/+1
|
* feat: goto def on impl items also goes to the defn in the traitJade2021-06-071-18/+56
| | | | | It was trivial to extend this to associated consts/associated types and I just didn't think of it.
* feat: goto definition on an impl fn goes to that fn in the traitJade2021-06-071-3/+48
| | | | | | | e.g. if you have a trait T and `impl T for S` for some struct, if you goto definition on some function name inside the impl, it will go to the definition of that function inside the `trait T` block, rather than the current behaviour of not going anywhere at all.
* Support goto-definition for include macro pathsLukas Wirth2021-06-051-3/+49
|
* internal: don't use `#[should_panic]` for testsAleksey Kladov2021-04-131-8/+10
|
* Support macros in pattern positionJonas Schievink2021-04-111-0/+26
|
* Merge #8245bors[bot]2021-04-051-5/+33
|\ | | | | | | | | | | | | | | | | | | 8245: Properly resolve intra doc links in hover and goto_definition r=matklad a=Veykril Unfortunately involves a bit of weird workarounds due to pulldown_cmark's incorrect lifetimes on `BrokenLinkCallback`... I should probably open an issue there asking for the fixes to be pushed to a release since they already exist in the repo for quite some time it seems. Fixes #8258, Fixes #8238 Co-authored-by: Lukas Wirth <[email protected]>
| * Use new new docs string source mapping in goto_def and hoverLukas Wirth2021-03-301-7/+12
| |
| * Implement basic Documentation source to syntax range mappingLukas Wirth2021-03-301-0/+1
| |
| * Properly resolve intra doc links in hover and goto_definitionLukas Wirth2021-03-301-1/+23
| |
* | Merge #8267bors[bot]2021-03-311-0/+2
|\ \ | |/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | 8267: Adding gifs and screenshots for features in manual r=matklad a=MozarellaMan For #6539 This includes most of gif or screenshot examples of most items in the "Features" header. With the exceptions of: - **On Typing Assists** - couldn't get it to work for a demo, I'm probably missing something? - **Structural search and replace** - looked to be already a visual example of the feature - **Workspace symbol** - wasn't sure how best to show this, all of the examples maybe? Also wasn't sure of the best code example to show it off - **Semantic Syntax Highlighting** - seemed obvious enough to not need a screenshot, but I could easily add this All the gifs/pngs are hosted in this [comment](https://github.com/rust-analyzer/rust-analyzer/issues/6539#issuecomment-809574840). Please let me know if any of them aren't suitable (and why) and I'll improve it! Or if you don't like the theme/font Co-authored-by: Ayomide Bamidele <[email protected]>
| * Gifs and screenshots for features in manualAyomide Bamidele2021-03-311-0/+2
| |
* | Accurately classify assoc. types in pathsJonas Schievink2021-03-301-0/+15
|/
* Show item info when hovering intra doc linksLukas Wirth2021-03-231-58/+8
|
* Add test for goto def on proc macro invocationJonas Schievink2021-03-181-0/+17
|
* Check whether cursor is on and not between intra doc links in goto_definitionLukas Wirth2021-03-171-8/+14
|
* Better handling of block doc commentsLukas Wirth2021-03-171-5/+3
|
* don't clone types that are copy (clippy::clone_on_copy)Matthias Krüger2021-03-171-1/+1
|
* Upgrade rowanAleksey Kladov2021-03-161-2/+2
| | | | Notably, new rowan comes with support for mutable syntax trees.
* Goto definition works for `S { a: }` caseAleksey Kladov2021-03-151-0/+11
| | | | | | | | | | | | | What happens here is that we lower `: ` to a missing expression, and then correctly record that the corresponding field expression resolves to a specific field. Where we fail is in the mapping of syntax to this missing expression. Doing it via `ast_field.expr()` fails, as that expression is `None`. Instead, we go in the opposite direcition and ask each lowered field about its source. This works, but has wrong complexity `O(N)` and, really, the implementation is just too complex. We need some better management of data here.
* Fix a few clippy::perf warningskjeremy2021-02-161-1/+1
|
* More precise navigation to parentAleksey Kladov2021-02-091-1/+0
|
* Cleanup testsAleksey Kladov2021-02-091-11/+1
|
* Cleanup testsAleksey Kladov2021-01-221-12/+12
|
* Remove index based fallback for goto defAleksey Kladov2021-01-221-48/+18
| | | | | We are so precise that the fallback creates more confusion, when you can goto def on an unresolved reference.
* Wrap remaining self/super/crate in Name{Ref}Lukas Wirth2021-01-151-5/+0
|
* Handle self/super/crate in PathSegment as NameRefLukas Wirth2021-01-151-29/+6
|
* Goto for inner doc links works for module inner doc commentsAleksey Kladov2021-01-111-26/+31
|
* Use hir::GenericParam in ide_db::Definition instead of relisting all 3Lukas Wirth2021-01-101-3/+1
|
* Support intra_doc linksDaiki Ihara2021-01-081-4/+86
|
* Change <|> to $0 - RebaseKevaundray Wedderburn2021-01-071-72/+72
|
* Merge #7030bors[bot]2020-12-241-0/+15
|\ | | | | | | | | | | | | | | | | | | 7030: Support labels in reference search r=matklad a=Veykril Implements general navigation for labels, goto def, rename and gives labels their own semantic highlighting class. Fixes #6966 Co-authored-by: Lukas Wirth <[email protected]>
| * Support labels in reference searchLukas Wirth2020-12-241-0/+15
| |
* | Store invocation site for eager macrosJonas Schievink2020-12-221-0/+25
|/
* Merge #6921bors[bot]2020-12-201-0/+28
|\ | | | | | | | | | | | | | | 6921: Higher-ranked trait bounds for where clauses r=flodiebold a=Veykril There is a slight problem with this which is also noted in a FIXME now but `LifetimeParameters` of these ForLifetime where clauses allocate the lifetimes in the corresponding arena as if they were lifetimes of the item itself and not just the clause they belong to. I wasn't entirely sure what I could do about this but given nothing really uses lifetimes like that currently I figured it might be fine? Open to suggestions for that problem. Co-authored-by: Lukas Wirth <[email protected]>
| * Higher-ranked trait bounds for where clausesLukas Wirth2020-12-171-0/+28
| |
* | NavTarget doesn't assume that it points to a symbolAleksey Kladov2020-12-181-1/+1
| |
* | Don't expose SyntaxKind from IDE APIAleksey Kladov2020-12-181-2/+2
|/ | | | | | SyntaxKind is somewhat of an internal type, but IDE is using it to basically specify an icon. Let's have a dedicated entity for this instead.
* Lifetime reference searchLukas Wirth2020-12-161-8/+49
|
* Support 'go to definition' for selfLukas Wirth2020-11-291-17/+39
|
* Support goto definition for ADT-SelfParamsLukas Wirth2020-11-281-6/+36
|
* Re-export base_db from ide_dbIgor Aleksanov2020-10-241-1/+1
|
* Clarify the names one more timeAleksey Kladov2020-10-151-2/+2
|
* More idiomatic classification APIAleksey Kladov2020-10-151-3/+3
|
* More clarificationsAleksey Kladov2020-10-151-1/+1
|
* Clarify NameClass names a bitAleksey Kladov2020-10-151-1/+1
|