aboutsummaryrefslogtreecommitdiff
path: root/crates
Commit message (Collapse)AuthorAgeFilesLines
...
* | | | | | Use AbsPathEdwin Cheng2021-01-221-3/+3
|/ / / / /
* | | | | Merge #7387bors[bot]2021-01-224-196/+228
|\ \ \ \ \ | |/ / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 7387: Refactor build script specific data r=edwin0cheng a=edwin0cheng It refactors for separating logic for build script specific data. bors r+ Co-authored-by: Edwin Cheng <[email protected]>
| * | | | Refactor build script dataEdwin Cheng2021-01-224-196/+228
| | | | |
* | | | | Remove unused fieldJonas Schievink2021-01-211-4/+0
| | | | |
* | | | | Add test for path resolution bugJonas Schievink2021-01-211-8/+33
|/ / / /
* | | | Revert "Make use of `block_def_map` in body lowering"Jonas Schievink2021-01-213-19/+18
| | | |
* | | | Merge #7378bors[bot]2021-01-217-2/+30
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 7378: Include `countme` crate to count important data structures. r=matklad a=matklad Co-authored-by: Aleksey Kladov <[email protected]>
| * | | | Include `countme` crate to count important data structures.Aleksey Kladov2021-01-217-2/+30
| | | | |
* | | | | Make use of `block_def_map` in body loweringJonas Schievink2021-01-213-18/+19
| | | | | | | | | | | | | | | | | | | | | | | | | Removes the `local_scope` hack from `Expander` in favor of tracking the `DefMap` in use during body lowering
* | | | | Remove unnecessary annotations from testsJonas Schievink2021-01-211-4/+0
|/ / / /
* | | | Add test for nameres in nested blocksJonas Schievink2021-01-211-0/+29
| | | |
* | | | Merge #7375bors[bot]2021-01-2110-58/+291
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 7375: Add support for running name resolution in block expressions r=jonas-schievink a=jonas-schievink This adds a `block_def_map` query that runs the name resolution algorithm on a block expression, and returns a `DefMap` that stores links to the parent `DefMap` (either the containing block or the crate-level `DefMap`). Blocks with no inner items return the parent's `DefMap` as-is, to avoid creating unnecessarily long `DefMap` chains. Path resolution is updated to recurse into the parent `DefMap` after looking up a path in the original `DefMap`. I've added a few new tests for this, but outside of those this isn't used yet. bors r+ Co-authored-by: Jonas Schievink <[email protected]>
| * | | | Add test that merges inner and outer namesJonas Schievink2021-01-211-0/+25
| | | | |
| * | | | Fix lowering with multiple block expressionsJonas Schievink2021-01-211-15/+23
| | | | |
| * | | | Fall back to parent DefMaps when resolving pathsJonas Schievink2021-01-211-0/+37
| | | | |
| * | | | Add name resolution query for block expressionsJonas Schievink2021-01-218-43/+206
| | | | |
* | | | | Merge #7372bors[bot]2021-01-211-1/+1
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 7372: Up lexer r=kjeremy a=kjeremy No real changes here. Co-authored-by: kjeremy <[email protected]>
| * | | | | Up lexerkjeremy2021-01-211-1/+1
| |/ / / /
* | | | | Merge #7371bors[bot]2021-01-211-0/+17
|\ \ \ \ \ | |/ / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | 7371: Change directory before running rustfmt to respect rustfmt.toml r=matklad a=lnicola Fixes #6973 Co-authored-by: Laurențiu Nicola <[email protected]>
| * | | | chdir to file before rustfmtLaurențiu Nicola2021-01-211-0/+17
| | | | |
* | | | | Merge #7368bors[bot]2021-01-212-5/+8
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 7368: Clarify enabled features and defined features in PackageData r=matklad a=edwin0cheng Co-authored-by: Edwin Cheng <[email protected]>
| * | | | | Added defined_features in PackageDataEdwin Cheng2021-01-212-5/+8
| |/ / / /
* / / / / Bump chalkLaurențiu Nicola2021-01-211-3/+3
|/ / / /
* | | | Treat BlockExpr as a potential module originJonas Schievink2021-01-208-7/+44
| | | |
* | | | Merge #7365bors[bot]2021-01-201-3/+3
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 7365: chalk 0.49.0 r=kjeremy a=kjeremy Co-authored-by: kjeremy <[email protected]>
| * | | | chalk 0.49.0kjeremy2021-01-201-3/+3
| | | | |
* | | | | DefMap: hide remaining crate-visible fieldsJonas Schievink2021-01-204-11/+23
|/ / / /
* | | | Merge #7359bors[bot]2021-01-203-32/+49
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 7359: ItemTree: store a mapping from blocks to inner items r=jonas-schievink a=jonas-schievink To do name resolution within block expressions, we need to know which inner items are located inside each block expression. This adds such a mapping to `ItemTree`, replacing the previous one, which was seemingly unused other than to access all the inner items. This also assigns `AstId`s to block expressions, which is needed to store the mapping in salsa. Co-authored-by: Jonas Schievink <[email protected]>
| * | | | Create a mapping from blocks to inner itemsJonas Schievink2021-01-202-26/+35
| | | | |
| * | | | Record `FileAstId`s for block expressiosnJonas Schievink2021-01-191-6/+14
| | | | | | | | | | | | | | | | | | | | | | | | | Every block expression may contain inner items, so we need to be able to refer to any block expression and use it as a salsa key.
* | | | | Make public DefMap fields privateJonas Schievink2021-01-2010-23/+31
| | | | |
* | | | | Merge #7350bors[bot]2021-01-202-9/+16
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 7350: Update pico-args r=matklad a=kjeremy Should maintain existing behavior Co-authored-by: kjeremy <[email protected]>
| * | | | | Update pico-argskjeremy2021-01-192-9/+16
| |/ / / / | | | | | | | | | | | | | | | Should maintains existing behavior
* | | | | Avoid intermediate collectionsAleksey Kladov2021-01-201-26/+20
| | | | |
* | | | | Don't show runnable suggestions for other filesAleksey Kladov2021-01-201-3/+32
| | | | | | | | | | | | | | | | | | | | | | | | | It't be actually great to have these once we have run anything dialog, but for run the thing at point it makes sense to show a limited set.
* | | | | :arrow_up: rowanAleksey Kladov2021-01-206-15/+9
| | | | | | | | | | | | | | | | | | | | It now stores text inline with tokens
* | | | | .Aleksey Kladov2021-01-1927-65/+69
| | | | |
* | | | | Merge #7352bors[bot]2021-01-194-6/+7
|\ \ \ \ \ | |_|_|/ / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 7352: :arrow_up: rowan r=matklad a=matklad bors r+ 🤖 Co-authored-by: Aleksey Kladov <[email protected]>
| * | | | :arrow_up: rowanAleksey Kladov2021-01-194-6/+7
| |/ / /
* | | | Merge #7351bors[bot]2021-01-194-12/+41
|\ \ \ \ | |/ / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 7351: Show const params in completions r=Veykril a=Veykril bors r+ ![image](https://user-images.githubusercontent.com/3757771/105080872-bba76680-5a91-11eb-91cd-0910da4c8312.png) Co-authored-by: Lukas Wirth <[email protected]>
| * | | Show const params in completionsLukas Wirth2021-01-194-12/+41
| | | |
* | | | Reduce TokenMap sizeEdwin Cheng2021-01-191-10/+16
| | | |
* | | | Merge #7321bors[bot]2021-01-192-73/+136
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 7321: Support runnables in macros r=matklad a=edwin0cheng fixes #4771 Co-authored-by: Edwin Cheng <[email protected]>
| * | | | Support runnables in macrosEdwin Cheng2021-01-192-73/+136
| | |/ / | |/| |
* | | | Merge #7342bors[bot]2021-01-198-36/+78
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 7342: Show deprecated completions for deprecated traits r=kjeremy a=SomeoneToIgnore TIL that there are two kinds of deprecation tags and a few details about String methods. <img width="472" alt="Screenshot 2021-01-19 at 01 11 38" src="https://user-images.githubusercontent.com/2690773/104970200-569d3380-59f3-11eb-9ee3-627b3c8a5c9d.png"> Co-authored-by: Kirill Bulatov <[email protected]>
| * | | | Show deprecated completions for deprecated traitsKirill Bulatov2021-01-188-28/+69
| | | | |
| * | | | Consider rustc_deprecated attr when checking for deprecationKirill Bulatov2021-01-181-8/+9
| | |/ / | |/| |
* | | | Merge #7341bors[bot]2021-01-183-2/+7
|\ \ \ \ | |/ / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 7341: Fix warnings when running `cargo doc --document-private-items` r=Veykril a=jyn514 These were the warnings previously: <details> ``` warning: could not parse code block as Rust code --> crates/stdx/src/lib.rs:137:9 | 137 | /// ∀ x in slice[..idx]: pred(x) | _________^ 138 | | /// && ∀ x in slice[idx..]: !pred(x) | |____^ | = note: error from rustc: unknown start of token: \u{2200} warning: 1 warning emitted warning: unresolved link to `package` --> crates/base_db/src/input.rs:181:15 | 181 | /// it's [package].name, can be different for other project types or even | ^^^^^^^ no item named `package` in scope | = note: `#[warn(broken_intra_doc_links)]` on by default = help: to escape `[` and `]` characters, add '\' before them like `\[` or `\]` warning: unresolved link to `package` --> crates/base_db/src/input.rs:181:15 | 181 | /// it's [package].name, can be different for other project types or even | ^^^^^^^ no item named `package` in scope | = help: to escape `[` and `]` characters, add '\' before them like `\[` or `\]` warning: 2 warnings emitted warning: unresolved link to `package` --> crates/base_db/src/input.rs:181:15 | 181 | /// it's [package].name, can be different for other project types or even | ^^^^^^^ no item named `package` in scope | = note: `#[warn(broken_intra_doc_links)]` on by default = help: to escape `[` and `]` characters, add '\' before them like `\[` or `\]` warning: unresolved link to `package` --> crates/base_db/src/input.rs:181:15 | 181 | /// it's [package].name, can be different for other project types or even | ^^^^^^^ no item named `package` in scope | = help: to escape `[` and `]` characters, add '\' before them like `\[` or `\]` warning: 2 warnings emitted ``` </details> This does *not* fix the following warning, because it is actually rust code and rustdoc is being over eager: ``` warning: Rust code block is empty --> crates/parser/src/grammar.rs:16:5 | 16 | //! ``` | _____^ 17 | | //! // test function_with_zero_parameters 18 | | //! // fn foo() {} 19 | | //! ``` | |_______^ | help: mark blocks that do not contain Rust code as text | 16 | //! ```text | ^^^^^^^ ``` https://github.com/rust-lang/rust/pull/79816 should make this configurable so the warning can be `allow`ed. Co-authored-by: Joshua Nelson <[email protected]>
| * | | Fix warnings when running `cargo doc --document-private-items`Joshua Nelson2021-01-183-2/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These were the warnings previously: ``` warning: could not parse code block as Rust code --> crates/stdx/src/lib.rs:137:9 | 137 | /// ∀ x in slice[..idx]: pred(x) | _________^ 138 | | /// && ∀ x in slice[idx..]: !pred(x) | |____^ | = note: error from rustc: unknown start of token: \u{2200} warning: 1 warning emitted warning: unresolved link to `package` --> crates/base_db/src/input.rs:181:15 | 181 | /// it's [package].name, can be different for other project types or even | ^^^^^^^ no item named `package` in scope | = note: `#[warn(broken_intra_doc_links)]` on by default = help: to escape `[` and `]` characters, add '\' before them like `\[` or `\]` warning: unresolved link to `package` --> crates/base_db/src/input.rs:181:15 | 181 | /// it's [package].name, can be different for other project types or even | ^^^^^^^ no item named `package` in scope | = help: to escape `[` and `]` characters, add '\' before them like `\[` or `\]` warning: 2 warnings emitted warning: unresolved link to `package` --> crates/base_db/src/input.rs:181:15 | 181 | /// it's [package].name, can be different for other project types or even | ^^^^^^^ no item named `package` in scope | = note: `#[warn(broken_intra_doc_links)]` on by default = help: to escape `[` and `]` characters, add '\' before them like `\[` or `\]` warning: unresolved link to `package` --> crates/base_db/src/input.rs:181:15 | 181 | /// it's [package].name, can be different for other project types or even | ^^^^^^^ no item named `package` in scope | = help: to escape `[` and `]` characters, add '\' before them like `\[` or `\]` warning: 2 warnings emitted ``` This does *not* fix the following warning, because it is actually rust code and rustdoc is being over eager: ``` warning: Rust code block is empty --> crates/parser/src/grammar.rs:16:5 | 16 | //! ``` | _____^ 17 | | //! // test function_with_zero_parameters 18 | | //! // fn foo() {} 19 | | //! ``` | |_______^ | help: mark blocks that do not contain Rust code as text | 16 | //! ```text | ^^^^^^^ ``` https://github.com/rust-lang/rust/pull/79816 should make this configurable so the warning can be `allow`ed.
* | | | Merge #7340bors[bot]2021-01-183-38/+20
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 7340: Remove obsolete RangeInfo usage in references r=Veykril a=Veykril Didn't even realize these were only here for renaming as well! bors r+ Co-authored-by: Lukas Wirth <[email protected]>