Skip to content

Subtree update of rust-analyzer #117701

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Merged
merged 245 commits into from
Nov 14, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
245 commits
Select commit Hold shift + click to select a range
940d87b
extend check.overrideCommand and buildScripts.overrideCommand docs re…
RalfJung Aug 21, 2023
2de62be
projects/workspaces
RalfJung Aug 21, 2023
23ffda1
full function signatures option
vxpm Sep 4, 2023
6afa5b0
better handling of spaces & newlines
vxpm Sep 4, 2023
6b487ed
fix & run tests
vxpm Sep 4, 2023
d7a8e80
feat: initial version of bool_to_enum assist
rmehri01 Aug 19, 2023
59738d5
fix: add generated doctest
rmehri01 Aug 19, 2023
83196fd
fix: remove trailing whitespace
rmehri01 Aug 19, 2023
91ac1d6
fix: initializing struct multiple times
Sep 8, 2023
455dacf
fix: only trigger assist on Name
Sep 8, 2023
136a9db
style: rename some locals
Sep 8, 2023
2e13aed
feat: support cross module imports
rmehri01 Sep 9, 2023
7ba2e13
fix: add checks for overwriting incorrect ancestor
rmehri01 Sep 10, 2023
5683df2
Deunwrap inline call
alibektas Aug 9, 2023
68d24b6
Deunwrap inline call v2
alibektas Sep 9, 2023
38491fc
v3
alibektas Sep 10, 2023
9c62571
Deunwrap convert_comment_block
alibektas Aug 9, 2023
b316bcc
replace for loops with sth more idiomatic
alibektas Aug 9, 2023
a66dbd1
v2
alibektas Aug 15, 2023
2fdf7e4
v3
alibektas Sep 10, 2023
25b1b3e
feat: add support for other ADT types and destructuring patterns
rmehri01 Sep 11, 2023
0863024
Make assist lazy again
alibektas Sep 11, 2023
893e191
Make assist lazy again
alibektas Sep 11, 2023
145a101
Deunwrap add_missing_match_arms
alibektas Sep 11, 2023
d794865
remove `as _` on auto importing on trait that is aliased with `_`
dfireBird Jul 22, 2023
df1239b
add tests for insert use with renamed imports
dfireBird Sep 11, 2023
2974416
fix: ensure `rustfmt` runs when configured with `./`
davidbarsky Sep 12, 2023
ebbbaaa
refactor: fix clippy lints
shogo-nakano-desu Sep 15, 2023
0bb2298
refactor: remove TODO with no explanation
shogo-nakano-desu Sep 15, 2023
96c3332
refactor: fix clippy lint
shogo-nakano-desu Sep 15, 2023
f4704bc
Switch to in-tree rustc dependencies with a cfg flag
HKalbasi Sep 15, 2023
24b6922
triagebot exclude_labels -> exclude_titles
pitaj Sep 16, 2023
cac796a
Give `unmerge_use` a label explaining what it will affect.
kpreid Sep 16, 2023
c372431
scip: Use load_workspace_at.
emilio Sep 19, 2023
cdaadb6
Auto merge of #15632 - emilio:scip-build-rs, r=lnicola
bors Sep 19, 2023
22b18b9
Auto merge of #15616 - HKalbasi:rustc-deps, r=HKalbasi
bors Sep 19, 2023
1841192
Do not resolve inlayHint.textEdit for VSCode client
SomeoneToIgnore Sep 19, 2023
f9fac02
Use proper editor name
SomeoneToIgnore Sep 19, 2023
0427a23
Auto merge of #15635 - SomeoneToIgnore:fix-vscode-edits, r=Veykril
bors Sep 19, 2023
3a63255
Update chalk version
Wilfred Sep 19, 2023
4b3257a
refactor: port anymap
shogo-nakano-desu Sep 16, 2023
00e238e
refactor: remove unnecesary cfg_attr and inline macro
shogo-nakano-desu Sep 19, 2023
f671b0b
refactor: move implementation inside anymap crate into stdx crate
shogo-nakano-desu Sep 19, 2023
6212182
refactor: remove hashbrown deps since we can use std
shogo-nakano-desu Sep 19, 2023
2b891ca
chore: add comments to mention anymap is a port from another repo
shogo-nakano-desu Sep 20, 2023
4778255
Auto merge of #15637 - Wilfred:update_chalk, r=lnicola
bors Sep 20, 2023
1e11a55
refactor: remove unnecesary deps that are blended in when rebase
shogo-nakano-desu Sep 20, 2023
dd84306
refactor: remove boxing
shogo-nakano-desu Sep 20, 2023
d6fef2c
Auto merge of #15621 - kpreid:import, r=Veykril
bors Sep 20, 2023
91b012f
Documentation: Add parenthesis to the list of on-typing assists.
tomalexander Sep 21, 2023
60f7473
fix parens when inlining closure local variables
rmehri01 Sep 22, 2023
ea11846
fix parens when inlining closure in body of function
rmehri01 Sep 22, 2023
c22bb03
Auto merge of #15651 - rmehri01:15639_fix_inline_local_closure, r=lni…
bors Sep 22, 2023
fccae08
Auto merge of #15649 - tomalexander:master, r=Veykril
bors Sep 22, 2023
11ffcc0
Auto merge of #15615 - shogo-nakano-desu:refactor/fix-clippy-lints, r…
bors Sep 22, 2023
93562dd
Use parent + and_then instead of ancestors
Veykril Sep 22, 2023
2ededa2
Auto merge of #15432 - alibektas:deunwrap/inline_call, r=Veykril
bors Sep 22, 2023
df75809
Auto merge of #15484 - rmehri01:14779_bool_to_enum_assist, r=Veykril
bors Sep 22, 2023
5855bd8
Auto merge of #15587 - dfireBird:fix-15128, r=Veykril
bors Sep 22, 2023
609bdbc
Auto merge of #15620 - pitaj:no-merges_exclude-titles, r=Veykril
bors Sep 22, 2023
556f0c6
Various small fixes
Veykril Sep 22, 2023
8ad536f
Make path start with a QualifiedPathType
alibektas Sep 15, 2023
695a134
Fix doctest
alibektas Sep 20, 2023
4a8622c
Auto merge of #15652 - Veykril:format_to, r=lnicola
bors Sep 22, 2023
0a91a54
v4
alibektas Sep 22, 2023
622e1a8
Add a test case to `add_missing_match_arms`
alibektas Sep 22, 2023
132a6ce
Omit QualPathTy when possible
alibektas Sep 22, 2023
59bcbaf
Auto merge of #15594 - alibektas:deunwrap/add_missing_match_arms, r=V…
bors Sep 22, 2023
ba7f2bf
Update config docs
Veykril Sep 22, 2023
8139e8e
Auto merge of #15425 - alibektas:deunwrap/convert_comment_block, r=Ve…
bors Sep 22, 2023
2b580a1
Auto merge of #15492 - RalfJung:invocation, r=Veykril
bors Sep 22, 2023
fc258de
Make QualPathTy case readable
alibektas Sep 22, 2023
9f3d627
add tests for full signatures
vxpm Sep 23, 2023
10fae62
split detail function
vxpm Sep 23, 2023
e5e937a
Auto merge of #15582 - vxpm:master, r=HKalbasi
bors Sep 24, 2023
7834b8f
Add `unused_variables` native diagnostic
HKalbasi Sep 24, 2023
ab52ba2
Fix unused_variables in tests
HKalbasi Sep 24, 2023
588c7d9
minor: hover_simple refactor
DaniPopes Sep 24, 2023
862a300
Auto merge of #15660 - DaniPopes:hover-simple-refactor, r=HKalbasi
bors Sep 24, 2023
7306504
fix panic with wrapping/unwrapping result return type assists
rmehri01 Sep 24, 2023
963ba59
minor: update libc to 0.2.148
chenx97 Sep 25, 2023
972a19f
Auto merge of #15659 - HKalbasi:unused-var, r=HKalbasi
bors Sep 25, 2023
f64eecd
fix one
Milo123459 Sep 25, 2023
85ead6e
remove other unwraps
Milo123459 Sep 25, 2023
d3cc3bc
Auto merge of #15665 - Milo123459:milo/remove-unwraps, r=lnicola
bors Sep 25, 2023
bce4be9
fix: make bool_to_enum assist create enum at top-level
rmehri01 Sep 26, 2023
73150c3
fix: wrap method call exprs in parens
rmehri01 Sep 26, 2023
6ca48d9
feat: add backtick to surrounding and auto-closing pairs
connorskees Sep 26, 2023
0dbde71
Simplify
Veykril Sep 26, 2023
b0fe99f
Auto merge of #15669 - Veykril:simplify, r=Veykril
bors Sep 26, 2023
c945f90
Auto merge of #15663 - chenx97:libc-148, r=Veykril
bors Sep 26, 2023
3b1b58c
Auto merge of #15662 - rmehri01:fix_panic_with_return_in_match, r=Vey…
bors Sep 26, 2023
6c907e1
Improve useRustcErrorCode description
veber-alex Sep 26, 2023
5b04a7d
Update editors/code/package.json
veber-alex Sep 27, 2023
f93b6ac
Auto merge of #15672 - veber-alex:useRustcErrorCode_descriptio, r=lni…
bors Sep 27, 2023
2b9dde1
Allocate ast ids for parameters
Veykril Sep 28, 2023
b3f4574
Auto merge of #15677 - Veykril:param-ast-id, r=Veykril
bors Sep 28, 2023
791e6c8
scip: Allow customizing cargo config.
emilio Sep 19, 2023
f19479a
Auto merge of #15633 - emilio:scip-cargo-config, r=lnicola
bors Sep 28, 2023
1b3e5b2
style: simplify node_to_insert_before
rmehri01 Sep 28, 2023
87e2c31
Auto merge of #15667 - rmehri01:bool_to_enum_top_level, r=Veykril
bors Sep 29, 2023
a382e64
Recover better on missing parameter in param list
Veykril Sep 29, 2023
50678e0
Auto merge of #15682 - Veykril:param-list-recov, r=Veykril
bors Sep 29, 2023
dfeff9f
Only run tests on linux in pull requests
Veykril Sep 29, 2023
1752178
Auto merge of #15686 - Veykril:param-list-recov, r=Veykril
bors Sep 29, 2023
53f5c1c
internal: re-generate lints.rs
DaniPopes Sep 29, 2023
e478db7
Auto merge of #15680 - DaniPopes:regenerate-lints, r=Veykril
bors Sep 29, 2023
a943b19
Make rustc_layout_scalar_valid_range attributes work for non-decimal …
Veykril Sep 29, 2023
547bcf8
Auto merge of #15688 - Veykril:rustc_layout_scalar_valid_range, r=Vey…
bors Sep 29, 2023
dd8ea97
vscode: Fix line and col regexp for problem matcher
Enselic Sep 29, 2023
ae5d74d
typing underscore should not trigger completions in types or patterns
Veykril Sep 29, 2023
4791a5d
Auto merge of #15692 - Veykril:underscore-completions, r=Veykril
bors Sep 29, 2023
af28458
Downgrade `unused_variables` to experimental
HKalbasi Sep 30, 2023
0840038
Auto merge of #15693 - HKalbasi:unused-var, r=HKalbasi
bors Sep 30, 2023
40f80e2
move `to_camel_case` and `char_has_case` from case_conv to stdx
rmehri01 Sep 30, 2023
2611fbf
implement basic version of convert_tuple_return_type_to_struct assist
rmehri01 Oct 1, 2023
146a7cc
fix: allow more kinds of if let patterns in guarded return assist
rmehri01 Oct 1, 2023
34d3490
feat: add assist for applying De Morgan's law to iterators
rmehri01 Oct 2, 2023
084ee93
Strip base prefix in layout_scalar_valid_range
lnicola Oct 2, 2023
d7faec8
Auto merge of #15701 - lnicola:rustc_layout_scalar_valid_range2, r=ln…
bors Oct 2, 2023
4c9d2c7
Auto merge of #15698 - rmehri01:15695_make_guarded_return_more_lenien…
bors Oct 2, 2023
7c113ee
Add mock description to rustc-dependencies
lnicola Oct 3, 2023
7b8330f
Auto merge of #15706 - lnicola:rustc-dependencies-description, r=lnicola
bors Oct 3, 2023
a8ec77d
address PR feedback.
davidbarsky Oct 3, 2023
fe39816
Recognize custom main function as binary entrypoint for runnables
Veykril Oct 4, 2023
36be913
Auto merge of #15709 - Veykril:runnables-custom-main, r=Veykril
bors Oct 4, 2023
c266387
Replace unwrap with expect
Veykril Oct 4, 2023
7e9da40
Auto merge of #15700 - rmehri01:15694_iterator_demorgan, r=Veykril
bors Oct 4, 2023
ad73597
Auto merge of #15690 - Enselic:fix-regexp, r=Veykril
bors Oct 4, 2023
9ba8dbc
style: clean up magic number for finding pattern usages
rmehri01 Oct 4, 2023
ab091b7
Add config for the default click action of extension status bar
dfireBird Oct 4, 2023
b57658d
Auto merge of #15707 - dfireBird:default-statusbar-action-config, r=l…
bors Oct 4, 2023
695c612
Auto merge of #15641 - alibektas:15598/fix_into_to_from, r=Veykril
bors Oct 5, 2023
4af730e
Do flyimport completions by prefix search for short paths
Veykril Oct 5, 2023
58239f2
Remove repetitive words
cuishuang Oct 5, 2023
e7295ff
Prepare for rust-bors
lnicola Oct 5, 2023
54866a0
Auto merge of #15668 - connorskees:feat/close-backtick, r=Veykril
bors Oct 5, 2023
fd39a30
Auto merge of #15712 - cuishuang:master, r=lnicola
bors Oct 5, 2023
03c5603
Auto merge of #15714 - lnicola:rust-bors, r=lnicola
bors Oct 5, 2023
114f8a0
Fix typos exec_intrinsic
Toby222 Oct 6, 2023
a158670
Auto merge of #15718 - Toby222:master, r=lnicola
bors Oct 6, 2023
88a00bf
Shrink PatPtr by swapping its AstPtr and Either wrap order
Veykril Oct 6, 2023
ef58843
Auto merge of #15721 - Veykril:shrink-pat-ptr, r=Veykril
bors Oct 6, 2023
b3ebc9a
Check for both path separators on windows
Veykril Oct 6, 2023
b1f89a8
Auto merge of #15600 - davidbarsky:davidbarsky/broken-rustfmt-in-ra, …
bors Oct 6, 2023
c5d9bfa
internal: fix automatic rustc/rustdoc lint generation
DaniPopes Oct 7, 2023
3dfc1bf
Use vscode.env.openExternal instead of the vscode.open command for docs
EliasHolzmann Oct 8, 2023
7e9b25b
Auto merge of #15725 - DaniPopes:fix-lintgen, r=Veykril
bors Oct 9, 2023
aeef7b6
Add config option to use `rust-analyzer` specific target dir
Tyrubias Sep 29, 2023
53b6700
Add dedicated `target_dir` field to `CargoConfig` and `FlycheckConfig`
Tyrubias Oct 1, 2023
ef0b3bb
Clarify documentation on new parameter
Tyrubias Oct 1, 2023
3682c37
Set `CARGO_TARGET_DIR` when using Flycheck custom command
Tyrubias Oct 1, 2023
2290cc3
Pass target directory as flag instead of env variable
Tyrubias Oct 4, 2023
9771e1e
Don't pass any target directory options to custom flycheck
Tyrubias Oct 9, 2023
a39d207
Addressed PR style comments
Tyrubias Oct 9, 2023
d646ae8
Auto merge of #15681 - Tyrubias:custom_target_dir, r=Veykril
bors Oct 9, 2023
0c4be03
feat: generate descriptors for all unstable features
DaniPopes Oct 7, 2023
dca63d1
Auto merge of #15713 - Veykril:flyimport-completions-short, r=Veykril
bors Oct 9, 2023
ab62c01
Auto merge of #15696 - rmehri01:14293_tuple_return_type_to_struct, r=…
bors Oct 9, 2023
aaa1e8e
Auto merge of #15618 - shogo-nakano-desu:internal/port-anymap, r=Veykril
bors Oct 9, 2023
e8372e0
vscode: Support opening local documentation if available
EliasHolzmann Oct 8, 2023
36eac9a
fix: add incorrect case diagnostics for module names
rmehri01 Oct 4, 2023
8a23314
Auto merge of #15728 - EliasHolzmann:feature/local_documentation_vsco…
bors Oct 10, 2023
a7fada4
add replace_is_some_with_if_let_some assist
Young-Flash Oct 11, 2023
1fe6ac8
add diagnosis messages for chars and byte literal errors
pvalletbo Oct 11, 2023
f58a825
fix: cargo fmt
pvalletbo Oct 11, 2023
c387361
Auto merge of #15744 - pvalletbo:15395/character-byte-literals-diagno…
bors Oct 11, 2023
677e6f3
fix: use unescape_byte function for Byte literals
pvalletbo Oct 11, 2023
e1aeb7f
fix: handle errors for string byte string and c_string
pvalletbo Oct 11, 2023
2e713a7
docs: Add Zed to IDE list.
osiewicz Oct 11, 2023
b769f34
chore: move common code to function
pvalletbo Oct 11, 2023
7eec17e
Auto merge of #15745 - osiewicz:add-zed-to-ide-list, r=lnicola
bors Oct 11, 2023
4b281ff
chore: format imports
pvalletbo Oct 11, 2023
6845c80
fix: format
pvalletbo Oct 11, 2023
3605bb3
fix CI: generate doctest
Young-Flash Oct 12, 2023
84e1d27
Auto merge of #15743 - Young-Flash:replace_is_some_with_if_let_some, …
bors Oct 12, 2023
506b1e5
feat: add replace_is_ok_with_if_let_ok assist
Young-Flash Oct 12, 2023
5bbca22
update mod order to adapt alphabetically sorted
Young-Flash Oct 12, 2023
862693f
Auto merge of #15752 - Young-Flash:replace_is_method_with_if_let_meth…
bors Oct 13, 2023
bc34e8f
feat: make cursor select at _tmp
Young-Flash Oct 14, 2023
3f4368a
fix: fix typo in mbe/lib.rs comment
harpsword Oct 14, 2023
16ac6c2
Auto merge of #15756 - harpsword:fix_typo_in_mbe_lib, r=lnicola
bors Oct 14, 2023
8217ff9
make ProjectionStore-impls pub-accessible
ChristianSchott Oct 14, 2023
dbe5392
Auto merge of #15760 - ChristianSchott:master, r=HKalbasi
bors Oct 14, 2023
65532e4
Auto merge of #15755 - Young-Flash:cursor_selection, r=lnicola
bors Oct 15, 2023
d33fd15
Fix metrics workflow to use deploy key
Veykril Oct 15, 2023
a8581aa
Auto merge of #15762 - Veykril:metrics-deploy, r=Veykril
bors Oct 15, 2023
40acc52
Update rustc_abi dependency
Veykril Sep 29, 2023
6572ec8
Auto merge of #15691 - Veykril:rustc_abi, r=Veykril
bors Oct 15, 2023
03bec11
Expand Emacs documentation
Wilfred Oct 15, 2023
983094a
Auto merge of #15764 - Wilfred:emacs_docs, r=lnicola
bors Oct 16, 2023
222be48
Create .ssh before writing deploy key
lnicola Oct 16, 2023
03f676e
Auto merge of #15769 - lnicola:metrics-ssh, r=lnicola
bors Oct 16, 2023
490cdfe
Fix metrics repo url
lnicola Oct 16, 2023
2910dbf
Auto merge of #15770 - lnicola:metrics-url, r=lnicola
bors Oct 16, 2023
d6afb4f
Auto merge of #15746 - pvalletbo:string-literals-diagnose, r=Veykril
bors Oct 16, 2023
1a0fe58
refactor: change generated variable name
Young-Flash Oct 17, 2023
7f1e6fd
Auto merge of #15775 - Young-Flash:refactor, r=Veykril
bors Oct 18, 2023
4296fe5
Add command for only opening external docs and attempt to fix vscode-…
Veykril Oct 18, 2023
4586a6b
Auto merge of #15779 - Veykril:open-docs, r=Veykril
bors Oct 18, 2023
a7f77d8
fix: auto import trait if needed
Young-Flash Oct 18, 2023
94eb142
Free up some disk space on auto-publish
lnicola Oct 19, 2023
0cae1ca
Auto merge of #15783 - lnicola:autopublish-space, r=lnicola
bors Oct 19, 2023
bd38871
Auto merge of #15736 - rmehri01:15678_module_incorrect_case_diagnosti…
bors Oct 20, 2023
954fb1d
Auto merge of #15727 - DaniPopes:lintgen-unstable-book, r=HKalbasi
bors Oct 20, 2023
094cecd
Fix VS Code detection for Insiders version
lnicola Oct 21, 2023
7c11399
Auto merge of #15786 - lnicola:detect-insiders, r=lnicola
bors Oct 21, 2023
4f5f7e2
feat: import trait with alias
Young-Flash Oct 22, 2023
8b82ea4
Store binding mode for each instance independently
HKalbasi Oct 22, 2023
1087295
Auto merge of #15789 - HKalbasi:unused-var, r=HKalbasi
bors Oct 22, 2023
45ee88f
fix: remove unwrap
Young-Flash Oct 23, 2023
2f6961a
Auto merge of #15780 - Young-Flash:auto_import, r=lnicola
bors Oct 23, 2023
99ec3aa
scip: update crate to version 0.3.1.
gigaroby Oct 26, 2023
46c395d
Auto merge of #15806 - gigaroby:master, r=lnicola
bors Oct 26, 2023
00cdbe6
feat: make extract_variable assist in place
Young-Flash Oct 27, 2023
7186a28
chore: add unapplicable test for extract_variable without select
Young-Flash Oct 28, 2023
f493207
Auto merge of #15809 - Young-Flash:extract_variable_in_place, r=HKalbasi
bors Oct 28, 2023
9c99afe
Fix some typos
cuishuang Oct 29, 2023
16f3398
Auto merge of #15812 - cuishuang:master, r=lnicola
bors Oct 30, 2023
9d290f1
chore: fix urls in guide.md
Sarrus1 Oct 30, 2023
a2e2881
Auto merge of #15815 - Sarrus1:chore/fix-guide-url, r=lnicola
bors Oct 30, 2023
a723acf
simplify the code
Young-Flash Oct 31, 2023
929544e
use `check_assist_by_label` to pick assist
Young-Flash Oct 31, 2023
99e94d2
Auto merge of #15788 - Young-Flash:import_anonymously, r=lnicola
bors Oct 31, 2023
740a864
feat: skip checking tt count for include macro call
Nov 1, 2023
b76f2c8
fix: using name(include) instead of str
Nov 2, 2023
11a263d
Auto merge of #15819 - wasd96040501:feat/skip_tt_count_limit, r=lnicola
bors Nov 2, 2023
1b7bb9a
VSCode search: 'category:formatters rust' metadata.
notpeter Nov 2, 2023
fccdde6
Maybe not a linter.
notpeter Nov 2, 2023
0fec61a
Auto merge of #15827 - notpeter:vscode_rust_formatter, r=lnicola
bors Nov 3, 2023
19bf0da
Fix docs path for derive macros
lnicola Nov 4, 2023
6943228
Auto merge of #15834 - lnicola:derive-docs, r=lnicola
bors Nov 4, 2023
8d8d121
feat: add generate_mut_trait_impl assist
Young-Flash Nov 4, 2023
b84940b
make generate_mut_trait_impl assist trigged for std trait only
Young-Flash Nov 5, 2023
c1c9e10
Auto merge of #15832 - Young-Flash:generate_mut_trait, r=lnicola
bors Nov 5, 2023
13249b7
fix: correct a typo in a comment in base-db/lib.rs
roife Nov 7, 2023
2a48432
Auto merge of #15843 - roife:master, r=lnicola
bors Nov 7, 2023
1086b29
update rustc dependencies
HKalbasi Nov 7, 2023
3b7c7f9
Auto merge of #15849 - HKalbasi:fix-sync, r=HKalbasi
bors Nov 7, 2023
626bd33
Merge commit '3b7c7f97e4a7bb253a8d398ee4f8346f6cf2817b' into sync-fro…
lnicola Nov 8, 2023
89a3fd4
Drop anymap license exception
lnicola Nov 10, 2023
01422d1
Allow rustc_private for RustAnalyzer
lnicola Nov 10, 2023
636a6f7
Try Mode::ToolRustc
lnicola Nov 13, 2023
c2c065c
Add missing rustc_private features
lnicola Nov 13, 2023
6ad73f5
Depend on rustc_driver
lnicola Nov 14, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/bootstrap/src/core/build_steps/check.rs
Original file line number Diff line number Diff line change
Expand Up @@ -376,12 +376,12 @@ impl Step for RustAnalyzer {
let compiler = builder.compiler(builder.top_stage, builder.config.build);
let target = self.target;

builder.ensure(Std::new(target));
builder.ensure(Rustc::new(target, builder));

let mut cargo = prepare_tool_cargo(
builder,
compiler,
Mode::ToolStd,
Mode::ToolRustc,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Couple lines above there is builder.ensure(Std::new(target));. Could you please replace it with builder.ensure(Rustc::new(target, builder));?

target,
cargo_subcommand(builder.kind),
"src/tools/rust-analyzer",
Expand Down Expand Up @@ -414,7 +414,7 @@ impl Step for RustAnalyzer {
/// Cargo's output path in a given stage, compiled by a particular
/// compiler for the specified target.
fn stamp(builder: &Builder<'_>, compiler: Compiler, target: TargetSelection) -> PathBuf {
builder.cargo_out(compiler, Mode::ToolStd, target).join(".rust-analyzer-check.stamp")
builder.cargo_out(compiler, Mode::ToolRustc, target).join(".rust-analyzer-check.stamp")
}
}
}
Expand Down
4 changes: 2 additions & 2 deletions src/bootstrap/src/core/build_steps/test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -369,7 +369,7 @@ impl Step for RustAnalyzer {

// We don't need to build the whole Rust Analyzer for the proc-macro-srv test suite,
// but we do need the standard library to be present.
builder.ensure(compile::Std::new(compiler, host));
builder.ensure(compile::Rustc::new(compiler, host));
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Like this? Or target? Or builder? 😅

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this seems fine


let workspace_path = "src/tools/rust-analyzer";
// until the whole RA test suite runs on `i686`, we only run
Expand All @@ -378,7 +378,7 @@ impl Step for RustAnalyzer {
let mut cargo = tool::prepare_tool_cargo(
builder,
compiler,
Mode::ToolStd,
Mode::ToolRustc,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here

host,
"test",
crate_path,
Expand Down
5 changes: 2 additions & 3 deletions src/bootstrap/src/core/build_steps/tool.rs
Original file line number Diff line number Diff line change
Expand Up @@ -603,8 +603,7 @@ pub struct RustAnalyzer {
}

impl RustAnalyzer {
pub const ALLOW_FEATURES: &'static str =
"proc_macro_internals,proc_macro_diagnostic,proc_macro_span,proc_macro_span_shrink";
pub const ALLOW_FEATURES: &'static str = "rustc_private,proc_macro_internals,proc_macro_diagnostic,proc_macro_span,proc_macro_span_shrink";
}

impl Step for RustAnalyzer {
Expand Down Expand Up @@ -636,7 +635,7 @@ impl Step for RustAnalyzer {
compiler: self.compiler,
target: self.target,
tool: "rust-analyzer",
mode: Mode::ToolStd,
mode: Mode::ToolRustc,
path: "src/tools/rust-analyzer",
extra_features: vec!["rust-analyzer/in-rust-tree".to_owned()],
is_optional_tool: false,
Expand Down
4 changes: 4 additions & 0 deletions src/tools/rust-analyzer/.github/workflows/autopublish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,10 @@ jobs:
with:
fetch-depth: 0

# https://github.com/jlumbroso/free-disk-space/blob/main/action.yml
- name: Free up some disk space
run: sudo rm -rf /usr/local/lib/android /usr/share/dotnet /opt/ghc /usr/local/.ghcup

- name: Install Rust toolchain
run: rustup update --no-self-update stable

Expand Down
2 changes: 2 additions & 0 deletions src/tools/rust-analyzer/.github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ on:
branches:
- auto
- try
- automation/bors/try

env:
CARGO_INCREMENTAL: 0
Expand Down Expand Up @@ -84,6 +85,7 @@ jobs:
run: cargo build --quiet ${{ env.USE_SYSROOT_ABI }}

- name: Test
if: matrix.os == 'ubuntu-latest' || github.event_name == 'push'
run: cargo test ${{ env.USE_SYSROOT_ABI }} -- --nocapture --quiet

- name: Switch to stable toolchain
Expand Down
9 changes: 6 additions & 3 deletions src/tools/rust-analyzer/.github/workflows/metrics.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -140,11 +140,14 @@ jobs:

- name: Combine json
run: |
git clone --depth 1 https://$METRICS_TOKEN@github.com/rust-analyzer/metrics.git
mkdir ~/.ssh
echo "${{ secrets.METRICS_DEPLOY_KEY }}" > ~/.ssh/id_ed25519
chmod 600 ~/.ssh/id_ed25519
chmod 700 ~/.ssh

git clone --depth 1 git@github.com:rust-analyzer/metrics.git
jq -s ".[0] * .[1] * .[2] * .[3] * .[4] * .[5]" build.json self.json ripgrep-13.0.0.json webrender-2022.json diesel-1.4.8.json hyper-0.14.18.json -c >> metrics/metrics.json
cd metrics
git add .
git -c user.name=Bot -c user.email=dummy@example.com commit --message 📈
git push origin master
env:
METRICS_TOKEN: ${{ secrets.METRICS_TOKEN }}
Loading