Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Support labels in reference search | Lukas Wirth | 2020-12-24 | 1 | -4/+15 |
| | |||||
* | Align code_model name with ungrammar | Aleksey Kladov | 2020-12-20 | 1 | -1/+1 |
| | |||||
* | Use more Rustic highlighting specifiers | Aleksey Kladov | 2020-12-19 | 1 | -10/+21 |
| | | | | | *Method* works for OO languages, but in rust we can also have associated constants & types, so let's move this to a modifier. | ||||
* | Deduplicate highlight tags and symbol kinds | Aleksey Kladov | 2020-12-18 | 1 | -47/+54 |
| | | | | | | | Curiously, LSP uses different enums for those, and unsurprising and annoyingly, there are things which exist in one but not in the other. Let's not repeat the mistake and unify the two things | ||||
* | Lifetime reference search | Lukas Wirth | 2020-12-16 | 1 | -0/+1 |
| | |||||
* | Move to upstream `macro_rules!` model | Jonas Schievink | 2020-12-15 | 1 | -23/+29 |
| | |||||
* | Use METHOD semantic token type | Laurențiu Nicola | 2020-12-04 | 1 | -5/+10 |
| | |||||
* | Add attribute highlight modifier to all tokens inside attributes | Lukas Wirth | 2020-11-21 | 1 | -3/+16 |
| | |||||
* | Merge #6472 | bors[bot] | 2020-11-09 | 1 | -1/+4 |
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 6472: Add `static` modifier for associated functions r=matklad a=p3achyjr Adds static semantic token modifier to associated functions, resolves #6194 ## Info - Associated functions are more-or-less equivalent to static methods in other languages. This PR checks, for each function, whether that function has a self_param, and whether it's enclosed in a trait/impl. ## Changes - Added method ```is_associated``` to code_model::Function. This basically gets the source from the ast, and checks whether the enclosing scope is an impl or trait. - Added `static` to HighlightModifiers - Added unit test ## Tests - Ran ```cargo test``` Co-authored-by: Anatol Liu <[email protected]> | ||||
| * | Add static semantic token modifier for associated functions with no &self | Anatol Liu | 2020-11-09 | 1 | -2/+2 |
| | | | | | | | | | | | | refactor logic into code_model.rs address comments | ||||
| * | Add static semantic token modifier for associated functions with no &self | Anatol Liu | 2020-11-08 | 1 | -1/+1 |
| | | | | | | | | | | | | refactor logic into code_model.rs address comments | ||||
| * | Add static semantic token modifier for associated functions with no &self | Anatol Liu | 2020-11-05 | 1 | -14/+2 |
| | | | | | | | | refactor logic into code_model.rs | ||||
| * | Add static semantic token modifier for associated functions with no &self | Anatol Liu | 2020-11-05 | 1 | -0/+15 |
| | | |||||
* | | . is an operator | Aleksey Kladov | 2020-11-09 | 1 | -1/+3 |
| | | | | | | | | closes #6498 | ||||
* | | Kill RAW_ literals | Aleksey Kladov | 2020-11-06 | 1 | -9/+7 |
|/ | | | | | Syntactically, they are indistinguishable from non-raw versions, so it doesn't make sense to separate then *at the syntax* level. | ||||
* | Remove more unreachable pubs | Aleksey Kladov | 2020-11-02 | 1 | -4/+5 |
| | |||||
* | Highlight never type as BuiltinType | Lukas Wirth | 2020-10-26 | 1 | -0/+3 |
| | |||||
* | Fix unary minus highlighting | Lukas Wirth | 2020-10-25 | 1 | -1/+8 |
| | |||||
* | Add Callable modifier for variables that implements Fnonce | GrayJack | 2020-10-16 | 1 | -1/+1 |
| | |||||
* | Add HighlightModifier::Callable and add it for locals | GrayJack | 2020-10-16 | 1 | -0/+3 |
| | |||||
* | More idiomatic classification API | Aleksey Kladov | 2020-10-15 | 1 | -3/+3 |
| | |||||
* | More clarifications | Aleksey Kladov | 2020-10-15 | 1 | -2/+2 |
| | |||||
* | Unconfuse expression and pattern field init shorthands | Aleksey Kladov | 2020-10-15 | 1 | -1/+1 |
| | |||||
* | Default::default the highlighters | Lukas Wirth | 2020-10-14 | 1 | -3/+3 |
| | |||||
* | Factor macro_rules! highlighting out | Lukas Wirth | 2020-10-14 | 1 | -117/+18 |
| | |||||
* | Factor format string highlighting out | Lukas Wirth | 2020-10-14 | 1 | -75/+8 |
| | |||||
* | Skip macro matcher fragment name semantic highlighting | Lukas Wirth | 2020-10-10 | 1 | -3/+115 |
| | |||||
* | Fix handling of consuming self, refactor shared logic into a single function | Paul Daniel Faria | 2020-09-06 | 1 | -29/+33 |
| | |||||
* | Add consuming modifier to lvalues that are passed by value and not Copy | Paul Daniel Faria | 2020-09-06 | 1 | -2/+39 |
| | |||||
* | Merge #5823 | bors[bot] | 2020-08-22 | 1 | -6/+0 |
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 5823: Don't underline function definition if self is &mut r=Nashenas88 a=matklad The self is right there, and is already underlined, so it makes little sense to emit even more underlines. before: ![before](https://user-images.githubusercontent.com/1711539/90672843-0d379500-e257-11ea-840f-b0caed4410f1.png) after: ![after](https://user-images.githubusercontent.com/1711539/90672840-0c9efe80-e257-11ea-9739-23af433841c6.png) Co-authored-by: Aleksey Kladov <[email protected]> | ||||
| * | Don't underline function definition if self is &mut | Aleksey Kladov | 2020-08-19 | 1 | -6/+0 |
| | | | | | | | | | | The self is right there, and is already underlined, so it makes little sense to emit even more underlines. | ||||
* | | :arrow_up: ungrammar | Aleksey Kladov | 2020-08-21 | 1 | -1/+2 |
|/ | |||||
* | Remove dead code | Aleksey Kladov | 2020-08-19 | 1 | -25/+15 |
| | |||||
* | Apply couple of rule of thumbs to simplify highlighting code | Aleksey Kladov | 2020-08-19 | 1 | -19/+16 |
| | | | | | | | | | | | | | | | | | Main one: instead of adding a parameter to function to handle special case, make the caller handle it. Second main one: make sure that function does a reasonable thing. `highlight_def` picks a color for def, *regardless* of the context the def is use. Feeding an info from the call-site muddies the responsibilities here. Minor smells, flagging the function as having space for improvement in the first place: * many parameters, some of which are set as constants on most call-sites (introduce severalfunction instad) * boolean param (add two functions instead) | ||||
* | Inline trivial function | Aleksey Kladov | 2020-08-19 | 1 | -8/+6 |
| | |||||
* | Simplify | Aleksey Kladov | 2020-08-19 | 1 | -9/+4 |
| | |||||
* | Minor | Aleksey Kladov | 2020-08-19 | 1 | -2/+1 |
| | |||||
* | Minor cleanups | Aleksey Kladov | 2020-08-19 | 1 | -1/+1 |
| | |||||
* | Better name | Aleksey Kladov | 2020-08-19 | 1 | -4/+4 |
| | |||||
* | Better API factoring around self access modes | Aleksey Kladov | 2020-08-19 | 1 | -10/+16 |
| | |||||
* | Add SelfParam to code_model | Aleksey Kladov | 2020-08-19 | 1 | -12/+8 |
| | |||||
* | Add new method to Semantics, method_receiver_kind, which returns the kind of ↵ | Paul Daniel Faria | 2020-08-16 | 1 | -65/+74 |
| | | | | | | | self The options are Shared, Mutable, Consuming, and Copied. Use this to add proper highlighting to methods based on usage. | ||||
* | Mark mutating functions with `mutable` modifier, and owning functions with ↵ | Paul Daniel Faria | 2020-08-16 | 1 | -10/+32 |
| | | | | `consuming`. | ||||
* | Rename ra_ide -> ide | Aleksey Kladov | 2020-08-13 | 1 | -0/+872 |