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 11 pull requests #79215

Closed
wants to merge 35 commits into from

Conversation

Dylan-DPC-zz
Copy link

Successful merges:

Failed merges:

r? @ghost
@rustbot modify labels: rollup

Create a similar rollup

CDirkx and others added 30 commits November 14, 2020 20:27
This was noticed while we were updating the embedded rust book: https://github.com/rust-embedded/book/pull/273/files

These targets do natively have atomic load/stores, but do not support CAS operations.
Otherwise code like this

    #![no_implicit_prelude]

    fn main() {
        ::std::todo!();
        ::std::unimplemented!();
    }

will fail to compile, which is unfortunate and presumably unintended.

This changes many invocations of `panic!` in a `macro_rules!` definition
to invocations of `$crate::panic!`, which makes the invocations hygienic.

Note that this does not make the built-in macro `assert!` hygienic.
* Switch a couple links over to intra-doc links
* Clean up some formatting/typography
We already set `compiletest` to use the local sysroot in rust-lang#68019, but
that missed the configuration for testing `compiletest` itself.
The `#[naked]` attribute disabled prologue / epilogue emission for the
function and it is responsibility of a developer to provide them. The
compiler is no position to inline such functions correctly.

Disable inlining of naked functions at LLVM and MIR level.
Collect derive placeholders using `collect` instead of `push`
…u-se

Qualify `panic!` as `core::panic!` in non-built-in `core` macros

Fixes rust-lang#78333.

-----

Otherwise code like this

    #![no_implicit_prelude]

    fn main() {
        ::std::todo!();
        ::std::unimplemented!();
    }

will fail to compile, which is unfortunate and presumably unintended.

This changes many invocations of `panic!` in a `macro_rules!` definition
to invocations of `$crate::panic!`, which makes the invocations hygienic.

Note that this does not make the built-in macro `assert!` hygienic.
Clarify availability of atomic operations

This was noticed while we were updating the embedded rust book: https://github.com/rust-embedded/book/pull/273/files

These targets do natively have atomic load/stores, but do not support CAS operations.
Add u128 and i128 integer tests

Add the missing integer tests for u128 and i128 for completeness with the other integer types.
Test drop order for (destructuring) assignments

Add a test that checks whether the drop order of `let` bindings is consistent with the drop order of the corresponding destructuring assignments.

Thanks to ``@RalfJung`` for the suggesting this test ([here](rust-lang#79016 (comment))) and an implementation!

r? ``@RalfJung``
…e-link, r=jyn514,GuillaumeGomez

rustdoc: add [src] links to methods on a trait's page

Closes rust-lang#45150

![image](https://user-images.githubusercontent.com/28781354/99565541-aba4d500-29c3-11eb-99c7-11c1f91584e9.png)

### Caveats

- The way I've implemented it, links are also provided for required methods, that just link to the signature in the code. I'm not sure if this is the desired behaviour.

![image](https://user-images.githubusercontent.com/28781354/99566222-849ad300-29c4-11eb-9897-08cc5842954f.png)

- I'm not sure if the css changes are correct. I inspected them visualy on firefox on desktop, and they seem to be fine.
- I can't tell how `src/librustdoc/html/render/mod.rs` is structured, so I probably
…=Mark-Simulacrum

Make compiletest testing use the local sysroot

We already set `compiletest` to use the local sysroot in rust-lang#68019, but
that missed the configuration for testing `compiletest` itself.
expand/resolve: Pre-requisites to "Turn `#[derive]` into a regular macro attribute"

Miscellaneous refactorings and error reporting changes extracted from rust-lang#79078.

Unlike rust-lang#79078 this PR doesn't make any observable changes to the language or library.
r? ``@Aaron1011``
Never inline naked functions

The `#[naked]` attribute disabled prologue / epilogue emission for the
function and it is responsibility of a developer to provide them. The
compiler is no position to inline such functions correctly.

Disable inlining of naked functions at LLVM and MIR level.

Closes rust-lang#60919.
…avidtwco

Revert rust-lang#78969 "Normalize function type during validation"

Closes rust-lang#79066.
Reopens rust-lang#78442.
…tmcm

Make as{_mut,}_slice on array::IntoIter public

The functions are useful in cases where you want to move data out of the IntoIter in bulk, by transmute_copy'ing the slice and then forgetting the IntoIter.

In the compiler, this is useful for providing a sped up IntoIter implementation. One can alternatively provide a separate allocate_array function but one can avoid duplicating some logic by passing everything through the generic iterator using interface.

As per suggestion in https://github.com/rust-lang/rust/pull/78569/files#r526506964
Add jyn514 email alias to mailmap

r? ``@jyn514``
@rustbot rustbot added the rollup A PR which is a rollup label Nov 19, 2020
@Dylan-DPC-zz
Copy link
Author

@bors r+ rollup=never p=5

@bors
Copy link
Contributor

bors commented Nov 19, 2020

📌 Commit 26f0226 has been approved by Dylan-DPC

@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 Nov 19, 2020
@bors
Copy link
Contributor

bors commented Nov 19, 2020

⌛ Testing commit 26f0226 with merge cb31ec3a2de4a0144c3e43cf4e43fb7399982c96...

@bors
Copy link
Contributor

bors commented Nov 19, 2020

💔 Test failed - checks-actions

@bors bors added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Nov 19, 2020
@m-ou-se
Copy link
Member

m-ou-se commented Nov 20, 2020

This failed on #79192, which has been fixed and merged.

@m-ou-se m-ou-se closed this Nov 20, 2020
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-review Status: Awaiting review from the assignee but also interested parties.
Projects
None yet
Development

Successfully merging this pull request may close these issues.