aboutsummaryrefslogtreecommitdiff
path: root/crates/hir_def/src/attr.rs
Commit message (Collapse)AuthorAgeFilesLines
* fix: false positive about inner attrs in docsAleksey Kladov2021-04-191-2/+2
| | | | closes #8541
* Avoid an unnecessary `collect`Jonas Schievink2021-04-091-3/+1
|
* Rename `Attr`s `index` field to `id`Jonas Schievink2021-04-091-8/+8
|
* Add `AttrId` to track attribute sourcesJonas Schievink2021-04-091-14/+17
|
* Avoid O(n²) when constructing AttrSourceMapJonas Schievink2021-04-061-9/+48
|
* Lower attributes on tuple fieldsJonas Schievink2021-04-061-5/+4
|
* Merge #8245bors[bot]2021-04-051-2/+93
|\ | | | | | | | | | | | | | | | | | | 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]>
| * Replace Range<usize> usage with TextRangeLukas Wirth2021-03-301-28/+14
| |
| * Implement basic Documentation source to syntax range mappingLukas Wirth2021-03-301-2/+107
| |
* | Make `ast_to_token_tree` infallibleJonas Schievink2021-04-041-1/+1
| | | | | | | | It could never return `None`, so reflect that in the return type
* | Intern Attr, MacroCall and Path componentsJonas Schievink2021-04-011-3/+4
|/
* clippy::complexity simplifications related to IteratorsMatthias Krüger2021-03-211-1/+1
|
* Add `AttrsWithOwner` and clean up `source_map`Jonas Schievink2021-03-191-123/+189
|
* Return `Either` from `MacroDefId::ast_id`Jonas Schievink2021-03-191-3/+4
|
* Merge #8097bors[bot]2021-03-191-1/+1
|\ | | | | | | | | | | | | | | 8097: Parse extended_key_value_attributes r=jonas-schievink a=Veykril Companion PR https://github.com/rust-analyzer/ungrammar/pull/31 Co-authored-by: Lukas Wirth <[email protected]>
| * Parse extended_key_value_attributesLukas Wirth2021-03-191-1/+1
| |
* | Merge #8083bors[bot]2021-03-181-16/+48
|\ \ | | | | | | | | | | | | | | | | | | | | | 8083: Track source file IDs in source mapping of Attrs r=jonas-schievink a=Veykril Fixes the panics/incorrect injection highlighting of outline module declarations until we figure out a nicer source mapping strategy for attributes. Co-authored-by: Lukas Wirth <[email protected]>
| * | Track source file IDs in source mapping of AttrsLukas Wirth2021-03-181-16/+48
| |/
* / Make MacroDefId's `AstId` mandatory when possibleJonas Schievink2021-03-181-1/+1
|/
* Make `ItemTreeId` its own typeJonas Schievink2021-03-181-1/+1
|
* Fix incorrect newline emission in Attrs::docsLukas Wirth2021-03-171-14/+14
|
* Better handling of block doc commentsLukas Wirth2021-03-171-38/+45
|
* Merge #8059bors[bot]2021-03-171-6/+39
|\ | | | | | | | | | | | | | | 8059: Move doc-comment highlight injection from AST to HIR r=matklad,jonas-schievink a=Veykril Fixes #5016 Co-authored-by: Lukas Wirth <[email protected]>
| * Remove quadratic attr source lookupLukas Wirth2021-03-171-0/+25
| |
| * Properly handle doc attributes in doc-comment highlight injectionLukas Wirth2021-03-161-1/+7
| |
| * Fix attribute index assignment in cfg_attr resolutionLukas Wirth2021-03-161-5/+7
| |
| * Move doc-comment highlight injection from AST to HIRLukas Wirth2021-03-161-1/+1
| |
* | avoid converting types into themselves via .into() (clippy::useless-conversion)Matthias Krüger2021-03-171-1/+1
|/ | | | example: let x: String = String::from("hello world").into();
* Handle `cfg_attr` gating multiple attributesJonas Schievink2021-03-131-29/+19
|
* Delete `ContainerId`Jonas Schievink2021-03-091-1/+1
|
* Use upstream cov-markLaurențiu Nicola2021-03-081-2/+1
|
* Fix some warningsLaurențiu Nicola2021-03-051-1/+1
|
* Return inner attributes of outline mod declarations in `attrs_query`Lukas Wirth2021-01-311-1/+9
|
* Obtain `ModuleId`'s `DefMap` through a methodJonas Schievink2021-01-221-1/+1
|
* Treat BlockExpr as a potential module originJonas Schievink2021-01-201-0/+1
|
* Remove map module from la-arena public APIAramis Razzaghipour2021-01-151-1/+1
| | | | | | It’s unlikely that more items will be added to the module, so it’s simpler for users if `ArenaMap` is re-exported and the module made private.
* prepare to publish el libro de arenaAleksey Kladov2021-01-141-1/+1
|
* Introduce new queries to computeDaniel Frampton2021-01-051-10/+46
| | | | | | | | 1) the set of attributes for all variants of an enum, and 2) the set of attributes for all fields of a variant. This avoids the current n^2 behavior when rendering completion for variants, which prevents completion for enums with large numbers of variants.
* Merge #7128bors[bot]2021-01-031-1/+20
|\ | | | | | | | | | | | | | | 7128: Implement HasAttrs for GenericParam r=matklad a=Veykril Co-authored-by: Lukas Wirth <[email protected]>
| * Impl HasAttrs for GenericParamLukas Wirth2021-01-011-1/+20
| |
* | Use fully qualified `Itertools::intersperse` call to silence nightly ↵cynecx2021-01-021-8/+7
|/ | | | warnings about a potential name collision due to recent libstd api additions
* Add API for mapping `Attr` back to its syntax nodeJonas Schievink2020-12-191-23/+55
|
* Make `RawAttrs` crate-privateJonas Schievink2020-12-191-2/+2
| | | | There should be no need to use this from outside
* Remove `Attrs::merge`Jonas Schievink2020-12-191-12/+0
| | | | Only the `RawAttrs` version of this is in use
* Remove resolved FIXMEJonas Schievink2020-12-191-1/+0
|
* More accurate `#[derive]` parsingJonas Schievink2020-12-191-3/+43
| | | | This now allows full paths to the derive macro
* Hit a markJonas Schievink2020-12-181-0/+3
|
* Fix parsing of active cfg_attrJonas Schievink2020-12-181-2/+2
|
* Implement `RawAttr::filter`Jonas Schievink2020-12-181-3/+61
|
* Refactor attributes API to allow handling cfg_attrJonas Schievink2020-12-181-53/+93
|