aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_ide_api
Commit message (Collapse)AuthorAgeFilesLines
...
* | rename syntax_mapping as wellAleksey Kladov2019-03-024-16/+15
| |
* | align lower module query namesAleksey Kladov2019-03-021-2/+1
| |
* | dont store body inside source mapAleksey Kladov2019-03-021-1/+1
| |
* | rename syntax-mapping -> source-mapAleksey Kladov2019-03-025-7/+7
| |
* | Update hover message since we do support globskjeremy2019-02-281-1/+1
|/
* Enable hover support for NamedFieldDefsVille Penttinen2019-02-271-3/+79
| | | | Additionally add type ascription for const and statics as well.
* Allow goto-definition to work for named fields in struct initializerVille Penttinen2019-02-272-0/+45
| | | | | Now goto definition should work when done on a named field in a struct initializer.
* Add support for hovering over the name of an itemVille Penttinen2019-02-272-2/+28
|
* Replace visit_fn with crate::completion::function_labelVille Penttinen2019-02-261-43/+2
|
* Add new type HoverResult to contain the results of hoveringVille Penttinen2019-02-262-15/+148
| | | | | This makes testing hovers easier as well as allows us to do more things with the results if needed.
* Add support for showing fn signature when hoveringVille Penttinen2019-02-261-3/+43
|
* rename type to type_alias in the AST as wellAleksey Kladov2019-02-254-7/+7
|
* complete patternsAleksey Kladov2019-02-243-0/+103
|
* Rename Type => TypeAliasFlorian Diebold2019-02-243-4/+4
|
* move testing functionsAleksey Kladov2019-02-2410-20/+14
|
* move the rest of presentation to presentationAleksey Kladov2019-02-242-50/+20
|
* move more code to presentationAleksey Kladov2019-02-242-88/+57
|
* move res completion to presentationAleksey Kladov2019-02-243-41/+42
|
* simplifyAleksey Kladov2019-02-241-31/+31
|
* move enum-variants to presentationAleksey Kladov2019-02-242-21/+21
|
* simplifyAleksey Kladov2019-02-244-35/+31
|
* move presentaion completion to presentationAleksey Kladov2019-02-242-80/+80
|
* move function rendering to presentationAleksey Kladov2019-02-245-24/+49
|
* introduce completion presentationAleksey Kladov2019-02-244-32/+41
| | | | | This module should remove completion rendering boilerplate from the "brains" of completion engine.
* complete fields in struct literalsAleksey Kladov2019-02-241-7/+16
|
* complete struct literalsAleksey Kladov2019-02-243-0/+72
|
* Assign IDs to assistsAleksey Kladov2019-02-242-4/+15
|
* Remove unnecessary to_nav_targetVille Penttinen2019-02-231-16/+12
|
* Add name_range field to FileSymbolVille Penttinen2019-02-232-7/+17
| | | | | | This contains the syntax range of the name itself, allowing NavigationTarget to properly set the focus_range. This should make it so that when using symbol based navigation, we should always focus on the name, instead of the full range.
* Fix NavigationTarget debug_render container_name outputVille Penttinen2019-02-231-1/+1
|
* Fix goto def not working when cursor was over the name of a defVille Penttinen2019-02-232-4/+126
| | | | | We now allow goto_definition to return the named NavigationTarget if the cursor is on the name of a definition.
* Merge #866bors[bot]2019-02-221-0/+20
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | 866: Implement basic support for Associated Methods r=flodiebold a=vipentti This is my attempt at learning to understand how the type inference works by adding basic support for associated methods. Currently it does not resolve associated types or constants. The basic idea is that `Resolver::resolve_path` returns a new `PathResult` type, which has two variants, `FullyResolved` and `PartiallyResolved`, fully resolved matches the previous behavior, where as `PartiallyResolved` contains the `PerNs<Resolution` in addition to a `segment_index` which contains the index of the segment which we failed to resolve. This index can then be used to continue inference in `infer_path_expr` using the `Type` we managed to resolve. This changes some of the previous apis, so looking for feedback and suggestions. This should enable fixing #832 Co-authored-by: Ville Penttinen <[email protected]>
| * Change resolve_path to return the fully resolved path or PerNs::noneVille Penttinen2019-02-222-2/+2
| | | | | | | | | | | | This also adds new pub(crate) resolve_path_segments which returns the PathResult, which may or may not be fully resolved. PathResult is also now pub(crate) since it is an implementation detail.
| * Implement basic support for Associated Methods and ConstantsVille Penttinen2019-02-213-2/+22
| | | | | | | | | | | | | | This is done in `infer_path_expr`. When `Resolver::resolve_path` returns `PartiallyResolved`, we use the returned `Resolution` together with the given `segment_index` to check if we can find something matching the segment at segment_index in the impls for that particular type.
* | Merge #864bors[bot]2019-02-211-0/+17
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 864: Fix handling of generics in tuple variants and refactor a bit r=matklad a=flodiebold (The problem was that we created separate substitutions for the return value, so we lost the connection between the type arguments in the constructor call and the type arguments of the result.) Also make them display a tiny bit nicer. Fixes #860. Co-authored-by: Florian Diebold <[email protected]> Co-authored-by: Florian Diebold <[email protected]>
| * | Fix handling of generics in tuple variants and refactor a bitFlorian Diebold2019-02-201-0/+17
| |/ | | | | | | | | | | Also make them display a tiny bit nicer. Fixes #860.
* / kill utils moduleAleksey Kladov2019-02-211-3/+2
|/
* remove ignored macro testsAleksey Kladov2019-02-192-19/+2
| | | | | we need to significantly reengineer macros, so the tests as they exist are useless
* more compact edits in instaAleksey Kladov2019-02-1855-1161/+339
|
* Don't use additional_text_edits API internallyAleksey Kladov2019-02-1856-378/+1274
|
* More orthogonal method namingAleksey Kladov2019-02-184-9/+4
|
* More compact debug representation for completionAleksey Kladov2019-02-1855-1883/+610
|
* Don't render `()` in calls to assoc functionsAleksey Kladov2019-02-173-6/+42
|
* Merge #844bors[bot]2019-02-174-37/+98
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 844: Refactor find_all_refs to return ReferenceSearchResult r=vipentti a=vipentti This refactors `find_all_refs` to return a new `ReferenceSearchResult` based on feedback in #839. There are few questions/notes regarding the refactor: 1. Introducing `NavigationTarget::from_bind_pat` this simply forwards the call to `NavigationTarget::from_named`, could we just expose `from_named` directly as `pub(crate)` ? 2. Added an utility method `NavigationTarget::range` since there were few places where you would use `self.focus_range.unwrap_or(self.full_range)` 3. Implementing `IntoIterator` for `ReferenceSearchResult`. This turns `ReferenceSearchResult` into an iterator over `FileRanges` and allows previous code to mostly stay as it was based on the order that `find_all_refs` previously had (declaration first and then the references). I'm not sure if there is a way of doing the conversion to `IntoIter` without the allocation of a new vector 4. Is it possible to have a binding without a name? I'm not sure if the `NavigationTarget::from_bind_pat` can cause some edge-cases that previously were ok This fixes #835. Co-authored-by: Ville Penttinen <[email protected]>
| * Remove leading ::Ville Penttinen2019-02-171-1/+1
| |
| * Refactor find_all_refs to return ReferenceSearchResultVille Penttinen2019-02-174-37/+98
| |
* | Unify with the autorefed/autoderefed receiver type during method resolutionFlorian Diebold2019-02-171-1/+1
|/
* Turn ImplBlock into a copy type just containing IDsFlorian Diebold2019-02-163-9/+15
| | | | | | | This makes it more like the other code model types. Also make Module::definition_source/declaration_source return HirFileIds, to make them more like the other source functions.
* document design guidelineAleksey Kladov2019-02-161-0/+6
|
* use better label for &mut ref completionAleksey Kladov2019-02-142-11/+11
|