Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Account for --remap-path-prefix in save-analysis #53110

Merged
merged 1 commit into from
Aug 9, 2018

Conversation

Xanewok
Copy link
Member

@Xanewok Xanewok commented Aug 6, 2018

Fixes #52549.

Didn't add a test since save-analysis is still unstable, only tested this locally. Should I add a test for that? If so, is run-make-fulldeps an appropriate format?

Session is already created with remapped working directory, so use that instead of the actual cwd.
This was the only place affected, since the rest of the paths in save-analysis are directly derived from files in spans from sess.codemap(), which already creates remapped ones.

r? @nrc

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Aug 6, 2018
@nrc
Copy link
Member

nrc commented Aug 8, 2018

@bors r+ rollup

(Doesn't need a test, the existing smoke tests will catch crashes)

@bors
Copy link
Contributor

bors commented Aug 8, 2018

📌 Commit e8bb7bf has been approved by nrc

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Aug 8, 2018
cramertj added a commit to cramertj/rust that referenced this pull request Aug 8, 2018
…=nrc

Account for --remap-path-prefix in save-analysis

Fixes rust-lang#52549.

Didn't add a test since save-analysis is still unstable, only tested this locally. Should I add a test for that? If so, is run-make-fulldeps an appropriate format?

Session is already created with remapped working directory, so use that instead of the actual cwd.
This was the only place affected, since the rest of the paths in save-analysis are directly derived from files in spans from `sess.codemap()`, which already creates remapped ones.

r? @nrc
cramertj added a commit to cramertj/rust that referenced this pull request Aug 8, 2018
…=nrc

Account for --remap-path-prefix in save-analysis

Fixes rust-lang#52549.

Didn't add a test since save-analysis is still unstable, only tested this locally. Should I add a test for that? If so, is run-make-fulldeps an appropriate format?

Session is already created with remapped working directory, so use that instead of the actual cwd.
This was the only place affected, since the rest of the paths in save-analysis are directly derived from files in spans from `sess.codemap()`, which already creates remapped ones.

r? @nrc
cramertj added a commit to cramertj/rust that referenced this pull request Aug 8, 2018
…=nrc

Account for --remap-path-prefix in save-analysis

Fixes rust-lang#52549.

Didn't add a test since save-analysis is still unstable, only tested this locally. Should I add a test for that? If so, is run-make-fulldeps an appropriate format?

Session is already created with remapped working directory, so use that instead of the actual cwd.
This was the only place affected, since the rest of the paths in save-analysis are directly derived from files in spans from `sess.codemap()`, which already creates remapped ones.

r? @nrc
cramertj added a commit to cramertj/rust that referenced this pull request Aug 8, 2018
…=nrc

Account for --remap-path-prefix in save-analysis

Fixes rust-lang#52549.

Didn't add a test since save-analysis is still unstable, only tested this locally. Should I add a test for that? If so, is run-make-fulldeps an appropriate format?

Session is already created with remapped working directory, so use that instead of the actual cwd.
This was the only place affected, since the rest of the paths in save-analysis are directly derived from files in spans from `sess.codemap()`, which already creates remapped ones.

r? @nrc
kennytm added a commit to kennytm/rust that referenced this pull request Aug 9, 2018
…=nrc

Account for --remap-path-prefix in save-analysis

Fixes rust-lang#52549.

Didn't add a test since save-analysis is still unstable, only tested this locally. Should I add a test for that? If so, is run-make-fulldeps an appropriate format?

Session is already created with remapped working directory, so use that instead of the actual cwd.
This was the only place affected, since the rest of the paths in save-analysis are directly derived from files in spans from `sess.codemap()`, which already creates remapped ones.

r? @nrc
bors added a commit that referenced this pull request Aug 9, 2018
Rollup of 15 pull requests

Successful merges:

 - #52773 (Avoid unnecessary pattern matching against Option and Result)
 - #53082 (Fix doc link (again))
 - #53094 (Automatically expand section if url id point to one of its component)
 - #53106 (atomic ordering docs)
 - #53110 (Account for --remap-path-prefix in save-analysis)
 - #53116 (NetBSD: fix signedess of char)
 - #53179 (Whitelist wasm32 simd128 target feature)
 - #53183 (Suggest comma when missing in macro call)
 - #53207 (Add individual docs for rotate_{left, right})
 - #53211 ([nll] enable feature(nll) on various crates for bootstrap)
 - #53214 ([nll] enable feature(nll) on various crates for bootstrap: part 2)
 - #53215 (Slightly refactor syntax_ext/format)
 - #53217 (inline some short functions)
 - #53219 ([nll] enable feature(nll) on various crates for bootstrap: part 3)
 - #53222 (A few cleanups for rustc_target)
@bors bors merged commit e8bb7bf into rust-lang:master Aug 9, 2018
@Xanewok Xanewok deleted the save-analysis-remap-path branch August 9, 2018 21:23
Xanewok added a commit to Xanewok/nuclide that referenced this pull request Aug 11, 2018
After hitting Buck build button, the relevant save-analysis Buck build
is performed and RLS is supplied with a dummy build command to retrieve
necessary save-analysis indexing files.

Things left to do/worth noting:
* We should detect if Buck is an appropriate build system for a given
LSP service and if not, not override RLS' external build command
* Until path remapping lands in rustc
(rust-lang/rust#53110) the index-based features
(find refs, goto def etc.) only work for source files in the
buck-out/**/$TARGET#save-analysis-container source files.
* RLS needs some bugfixin' since currently external build command does
not properly refresh file dirty state, leading to an endless build loop.
Xanewok added a commit to Xanewok/nuclide that referenced this pull request Aug 31, 2018
After hitting Buck build button, the relevant save-analysis Buck build
is performed and RLS is supplied with a dummy build command to retrieve
necessary save-analysis indexing files.

Things left to do/worth noting:
* We should detect if Buck is an appropriate build system for a given
LSP service and if not, not override RLS' external build command
* Until path remapping lands in rustc
(rust-lang/rust#53110) the index-based features
(find refs, goto def etc.) only work for source files in the
buck-out/**/$TARGET#save-analysis-container source files.
* RLS needs some bugfixin' since currently external build command does
not properly refresh file dirty state, leading to an endless build loop.
Xanewok added a commit to Xanewok/nuclide that referenced this pull request Sep 14, 2018
After hitting Buck build button, the relevant save-analysis Buck build
is performed and RLS is supplied with a dummy build command to retrieve
necessary save-analysis indexing files.

Things left to do/worth noting:
* We should detect if Buck is an appropriate build system for a given
LSP service and if not, not override RLS' external build command
* Until path remapping lands in rustc
(rust-lang/rust#53110) the index-based features
(find refs, goto def etc.) only work for source files in the
buck-out/**/$TARGET#save-analysis-container source files.
* RLS needs some bugfixin' since currently external build command does
not properly refresh file dirty state, leading to an endless build loop.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants