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 6 pull requests #71689

Merged
merged 15 commits into from
Apr 29, 2020
Merged

Rollup of 6 pull requests #71689

merged 15 commits into from
Apr 29, 2020

Conversation

Dylan-DPC-zz
Copy link

Successful merges:

Failed merges:

r? @ghost

CohenArthur and others added 15 commits April 23, 2020 22:22
Changed raw pointer name from ptr to raw_pointer to avoid confusion with
the `use std::ptr` statement a few lines above. This way the crate name
and pointer name are well differenciated.
If it is possible to convert an integer type into another using
`into`, don't suggest `try_into`. This commit changes the suggested
method to convert from one integer type to another for the following
cases:

- u{n} -> i{m} where n < m
- u8 -> isize
- i{n} -> isize where n <= 16
- u{n} -> usize where n <= 16
Since Into<isize> is not implemented for uint of width greater than 8
Remove `integer-into.rs` since the numeric-cast tests already cover
these cases.
Add documentation example to slice_from_raw_parts_mut()
Add SAFETY explanations to some unsafe blocks in libcore/ptr

* libcore/ptr/mod.rs
* libcore/ptr/unique.rs
* libcore/ptr/non_null.rs

safety-mod.rs: Add SAFETY to slice_from_raw_parts(),
slice_from_raw_parts_mut()

slice_from_raw_parts_mut: Add documentation example

safety-ptr-unique.rs: Add SAFETY to new() and cast()

safety-ptr-non_null.rs: Add SAFETY to new()

safety-ptr-non_null.rs: Add SAFETY to cast()

safety-ptr-non_null.rs: Add SAFETY to from() impls

safety-ptr-unique.rs: Add SAFETY to from() impls

safety-ptr-non_null.rs: Add SAFETY to new()

safety-ptr-unique.rs: Add SAFETY to new()

safety-ptr-mod.rs: Fix safety explanation

rust-lang#71507 (comment)

safety-prt-non_null.rs: Fix SAFETY comment syntax

safety-ptr-unique.rs: Fix syntax for empty()

safety-ptr-non_null.rs: Fix misuse of non-null for align_of()

safety-ptr-non_null.rs: Remove incorrect SAFETY comment

safety-ptr-unique.rs: Remove unsound SAFETY comment

safety-ptr-mod.rs: Add std comment on slice_from_raw_parts guarantee

safety-ptr-unique.rs: Remove incorrect safety comment

Creating a Unique from a NonNull has strict guarantees that the current
implementation does not guarantee

rust-lang#71507 (comment)

safety-ptr: Re-adding ignore-tidy directive
The `Eq` link was incorrectly going to the `eq` method of `PartialEq`
instead of to the `Eq` trait.
…-ptr, r=Mark-Simulacrum

Document unsafety in core::ptr

Contributes to rust-lang#66219

I have yet to document all the `unsafe` blocks in the lib and would like to know if I'm headed in the right direction

r? @steveklabnik
test iterator chain type length blowup

Adds a regression test. closes rust-lang#58952

r? @Dylan-DPC
…-morse

Suggest `into` instead of `try_into` if possible with int types

If it is possible to convert an integer type into another using `into`, don't suggest `try_into`. This commit changes the suggested method to convert from one integer type to another for the following cases:

- u{n} -> i{m} where n < m
- u8 -> isize
- i{n} -> isize where n <= 16
- u{n} -> usize where n <= 16

Fixes rust-lang#71580
Fix wrong argument in autoderef process

The `overloaded_deref_ty` is a function for derefencing a type which overloads the `Deref` trait. But actually this function never uses the parameter pushed in until this PR. -_-
…acrum

Add an index page for nightly rustc docs.

This adds an `index.html` page at the root of the nightly-rustc docs so that the URL https://doc.rust-lang.org/nightly/nightly-rustc/ should have a landing page that lists all the crates.
…r=Mark-Simulacrum

Fix doc link to Eq trait from PartialEq trait

The `Eq` link was incorrectly going to the `eq` method of `PartialEq`
instead of to the `Eq` trait.
@Dylan-DPC-zz
Copy link
Author

@bors r+ p=6 rollup=never

@bors
Copy link
Contributor

bors commented Apr 29, 2020

📌 Commit d11b559 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 Apr 29, 2020
@bors
Copy link
Contributor

bors commented Apr 29, 2020

⌛ Testing commit d11b559 with merge fa51f81...

@bors
Copy link
Contributor

bors commented Apr 29, 2020

☀️ Test successful - checks-azure
Approved by: Dylan-DPC
Pushing fa51f81 to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Apr 29, 2020
@bors bors merged commit fa51f81 into rust-lang:master Apr 29, 2020
@rust-highfive
Copy link
Collaborator

📣 Toolstate changed by #71689!

Tested on commit fa51f81.
Direct link to PR: #71689

💔 rustc-dev-guide on linux: test-pass → test-fail (cc @JohnTitor @amanjeev @spastorino @mark-i-m).

rust-highfive added a commit to rust-lang-nursery/rust-toolstate that referenced this pull request Apr 29, 2020
Tested on commit rust-lang/rust@fa51f81.
Direct link to PR: <rust-lang/rust#71689>

💔 rustc-dev-guide on linux: test-pass → test-fail (cc @JohnTitor @amanjeev @spastorino @mark-i-m).
@Dylan-DPC-zz Dylan-DPC-zz deleted the rollup-8nyuwm1 branch July 30, 2020 00:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
merged-by-bors This PR was explicitly merged by bors. 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.

10 participants