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

Rollup of 5 pull requests #65797

Closed
wants to merge 17 commits into from
Closed

Conversation

Centril
Copy link
Contributor

@Centril Centril commented Oct 25, 2019

Successful merges:

Failed merges:

r? @ghost

Rantanen and others added 17 commits October 21, 2019 19:28
This prepares the code base for when projection is interned. Place's
projection field is going to be `&List<PlaceElem<'tcx>>` so we won't be
able to pattern match against it.
This is so we avoid a massive break of other people's code. Gonna run
rustfmt and split the file on a different PR.
It was allocating a new OsString that was immediately dropped after
using it with set_file_name. Now it directly changes the extension in
the original buffer, without touching the rest of the file name or
allocating a temporary string.
Fix the start/end byte positions in the compiler JSON output

Track the changes made during normalization in the `SourceFile` and use this information to correct the `start_byte` and `end_byte` fields in the JSON output.

This should ensure the start/end byte fields can be used to index the original file, even if Rust normalized the source code for parsing purposes. Both CRLF to LF and BOM removal are handled with this one.

The rough plan was discussed with @matklad in rust-lang/rustfix#176 - although I ended up going with `u32` offset tracking so I wouldn't need to deal with `u32 + i32` arithmetics when applying the offset to the span byte positions.

Fixes rust-lang#65029
… r=oli-obk

Intern place projection

This should sit on top of rust-lang#65197. After that one merged, I'm gonna rebase on top of it.

The important commits are the last three and there's a bunch of code repetition that I'm going to remove but for that I need to refactor some things that probably need to be added before this PR.

Anyway this work helps as is because we can run perf tests :).

r? @oli-obk /cc @nikomatsakis
Fix check of `statx` and handle EPERM

Should fix rust-lang#65662

rust-lang#65662 (comment)
> I think a reasonable solution might be to do something like try to stat AT_CWD initially and if that fails with EPERM or ENOSYS we disable the syscall entirely, otherwise it's cached as always good to use.

r? @alexcrichton
…ion, r=dtolnay

Prevent unnecessary allocation in PathBuf::set_extension.

It was allocating a new `OsString` that was immediately dropped after using it with `set_file_name`. Now it directly changes the extension in the original buffer, without touching the rest of the file name or allocating a temporary string.
…-feature, r=Dylan-DPC

Fix default "disable-shortcuts" feature value

Follow-up of rust-lang#65656

It fixes the bad handling of the default value of the feature (which would disable shortcut by default, which is bad!).

r? @Dylan-DPC
cc @kinnison
@Centril
Copy link
Contributor Author

Centril commented Oct 25, 2019

@bors r+ p=5 rollup=never

@bors
Copy link
Contributor

bors commented Oct 25, 2019

📌 Commit 902f940 has been approved by Centril

@bors bors added the S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. label Oct 25, 2019
@Centril Centril added the rollup A PR which is a rollup label Oct 25, 2019
@bors
Copy link
Contributor

bors commented Oct 25, 2019

⌛ Testing commit 902f940 with merge 49fa0904a5e76bc2fa52fe2b9777c88ffa171035...

@Centril
Copy link
Contributor Author

Centril commented Oct 25, 2019

@bors r- retry

@bors bors added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. 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-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Oct 25, 2019
@Centril Centril closed this Oct 25, 2019
@Centril Centril deleted the rollup-8g0svi5 branch October 25, 2019 11:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
rollup A PR which is a rollup 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.

7 participants