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

Implement Unpin for Box, Rc, and Arc #53874

Merged
merged 4 commits into from Sep 7, 2018

Conversation

Projects
None yet
9 participants
@withoutboats
Contributor

withoutboats commented Aug 31, 2018

Per the discussion in #49150, these should implement Unpin even if what they point to does not.

@rust-highfive

This comment has been minimized.

Show comment
Hide comment
@rust-highfive

rust-highfive Aug 31, 2018

Collaborator

r? @KodrAus

(rust_highfive has picked a reviewer for you, use r? to override)

Collaborator

rust-highfive commented Aug 31, 2018

r? @KodrAus

(rust_highfive has picked a reviewer for you, use r? to override)

@withoutboats

This comment has been minimized.

Show comment
Hide comment
@withoutboats
Contributor

withoutboats commented Aug 31, 2018

@rust-highfive

This comment has been minimized.

Show comment
Hide comment
@rust-highfive

rust-highfive Sep 1, 2018

Collaborator

The job x86_64-gnu-llvm-5.0 of your PR failed on Travis (raw log). Through arcane magic we have determined that the following fragments from the build log may contain information about the problem.

Click to expand the log.
/usr/local/lib/python2.7/dist-packages/pip/_vendor/requests/packages/urllib3/util/ssl_.py:122: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.io/en/latest/security.html#insecureplatformwarning.
  InsecurePlatformWarning
/usr/local/lib/python2.7/dist-packages/pip/_vendor/requests/packages/urllib3/util/ssl_.py:122: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.io/en/latest/security.html#insecureplatformwarning.
  InsecurePlatformWarning
  Downloading https://files.pythonhosted.org/packages/d7/d2/04d4fb0da66c7a8850477ff1fb8f9e80597147286e118e111f7d548cf1d7/awscli-1.16.6-py2.py3-none-any.whl (1.3MB)
    0% |▎                               | 10kB 13.9MB/s eta 0:00:01
    1% |▌                               | 20kB 1.9MB/s eta 0:00:01
    2% |▊                               | 30kB 2.2MB/s eta 0:00:01
    3% |█                               | 40kB 2.0MB/s eta 0:00:01

I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact @TimNN. (Feature Requests)

Collaborator

rust-highfive commented Sep 1, 2018

The job x86_64-gnu-llvm-5.0 of your PR failed on Travis (raw log). Through arcane magic we have determined that the following fragments from the build log may contain information about the problem.

Click to expand the log.
/usr/local/lib/python2.7/dist-packages/pip/_vendor/requests/packages/urllib3/util/ssl_.py:122: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.io/en/latest/security.html#insecureplatformwarning.
  InsecurePlatformWarning
/usr/local/lib/python2.7/dist-packages/pip/_vendor/requests/packages/urllib3/util/ssl_.py:122: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.io/en/latest/security.html#insecureplatformwarning.
  InsecurePlatformWarning
  Downloading https://files.pythonhosted.org/packages/d7/d2/04d4fb0da66c7a8850477ff1fb8f9e80597147286e118e111f7d548cf1d7/awscli-1.16.6-py2.py3-none-any.whl (1.3MB)
    0% |▎                               | 10kB 13.9MB/s eta 0:00:01
    1% |▌                               | 20kB 1.9MB/s eta 0:00:01
    2% |▊                               | 30kB 2.2MB/s eta 0:00:01
    3% |█                               | 40kB 2.0MB/s eta 0:00:01

I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact @TimNN. (Feature Requests)

Show outdated Hide outdated src/liballoc/rc.rs
Show outdated Hide outdated src/liballoc/boxed.rs
@RalfJung

This comment has been minimized.

Show comment
Hide comment
@RalfJung

RalfJung Sep 1, 2018

Member

LGTM, but I feel those arguments about Box possibly being both ways, and about pinning being structural for fields but not for pointer indirections, should also be written down in comments somewhere in the code.

r=me with that comment added.

Member

RalfJung commented Sep 1, 2018

LGTM, but I feel those arguments about Box possibly being both ways, and about pinning being structural for fields but not for pointer indirections, should also be written down in comments somewhere in the code.

r=me with that comment added.

@withoutboats

This comment has been minimized.

Show comment
Hide comment
@withoutboats

withoutboats Sep 5, 2018

Contributor

@bors r=RalfJung

Contributor

withoutboats commented Sep 5, 2018

@bors r=RalfJung

@bors

This comment has been minimized.

Show comment
Hide comment
@bors

bors Sep 5, 2018

Contributor

📌 Commit c82af09 has been approved by RalfJung

Contributor

bors commented Sep 5, 2018

📌 Commit c82af09 has been approved by RalfJung

@rust-highfive

This comment has been minimized.

Show comment
Hide comment
@rust-highfive

rust-highfive Sep 5, 2018

Collaborator

The job x86_64-gnu-llvm-5.0 of your PR failed on Travis (raw log). Through arcane magic we have determined that the following fragments from the build log may contain information about the problem.

Click to expand the log.

[00:06:50] travis_fold:start:tidy
travis_time:start:tidy
tidy check
[00:06:50] tidy error: /checkout/src/liballoc/boxed.rs:754: trailing whitespace
[00:06:52] some tidy checks failed
[00:06:52] 
[00:06:52] 
[00:06:52] command did not execute successfully: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage0-tools-bin/tidy" "/checkout/src" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage0/bin/cargo" "--no-vendor" "--quiet"
[00:06:52] 
[00:06:52] 
[00:06:52] failed to run: /checkout/obj/build/bootstrap/debug/bootstrap test src/tools/tidy
[00:06:52] Build completed unsuccessfully in 0:00:51
[00:06:52] Build completed unsuccessfully in 0:00:51
[00:06:52] make: *** [tidy] Error 1
[00:06:52] Makefile:79: recipe for target 'tidy' failed

The command "stamp sh -x -c "$RUN_SCRIPT"" exited with 2.
travis_time:start:090e55ea
$ date && (curl -fs --head https://google.com | grep ^Date: | sed 's/Date: //g' || true)
---
travis_time:end:14559ba0:start=1536184653303742405,finish=1536184653312308198,duration=8565793
travis_fold:end:after_failure.3
travis_fold:start:after_failure.4
travis_time:start:16a90cbb
$ ln -s . checkout && for CORE in obj/cores/core.*; do EXE=$(echo $CORE | sed 's|obj/cores/core\.[0-9]*\.!checkout!\(.*\)|\1|;y|!|/|'); if [ -f "$EXE" ]; then printf travis_fold":start:crashlog\n\033[31;1m%s\033[0m\n" "$CORE"; gdb -q -c "$CORE" "$EXE" -iex 'set auto-load off' -iex 'dir src/' -iex 'set sysroot .' -ex bt -ex q; echo travis_fold":"end:crashlog; fi; done || true
travis_fold:end:after_failure.4
travis_fold:start:after_failure.5
travis_time:start:383c0220
travis_time:start:383c0220
$ cat ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers || true
cat: ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers: No such file or directory
travis_fold:end:after_failure.5
travis_fold:start:after_failure.6
travis_time:start:2f34c2f1
$ dmesg | grep -i kill

I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact @TimNN. (Feature Requests)

Collaborator

rust-highfive commented Sep 5, 2018

The job x86_64-gnu-llvm-5.0 of your PR failed on Travis (raw log). Through arcane magic we have determined that the following fragments from the build log may contain information about the problem.

Click to expand the log.

[00:06:50] travis_fold:start:tidy
travis_time:start:tidy
tidy check
[00:06:50] tidy error: /checkout/src/liballoc/boxed.rs:754: trailing whitespace
[00:06:52] some tidy checks failed
[00:06:52] 
[00:06:52] 
[00:06:52] command did not execute successfully: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage0-tools-bin/tidy" "/checkout/src" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage0/bin/cargo" "--no-vendor" "--quiet"
[00:06:52] 
[00:06:52] 
[00:06:52] failed to run: /checkout/obj/build/bootstrap/debug/bootstrap test src/tools/tidy
[00:06:52] Build completed unsuccessfully in 0:00:51
[00:06:52] Build completed unsuccessfully in 0:00:51
[00:06:52] make: *** [tidy] Error 1
[00:06:52] Makefile:79: recipe for target 'tidy' failed

The command "stamp sh -x -c "$RUN_SCRIPT"" exited with 2.
travis_time:start:090e55ea
$ date && (curl -fs --head https://google.com | grep ^Date: | sed 's/Date: //g' || true)
---
travis_time:end:14559ba0:start=1536184653303742405,finish=1536184653312308198,duration=8565793
travis_fold:end:after_failure.3
travis_fold:start:after_failure.4
travis_time:start:16a90cbb
$ ln -s . checkout && for CORE in obj/cores/core.*; do EXE=$(echo $CORE | sed 's|obj/cores/core\.[0-9]*\.!checkout!\(.*\)|\1|;y|!|/|'); if [ -f "$EXE" ]; then printf travis_fold":start:crashlog\n\033[31;1m%s\033[0m\n" "$CORE"; gdb -q -c "$CORE" "$EXE" -iex 'set auto-load off' -iex 'dir src/' -iex 'set sysroot .' -ex bt -ex q; echo travis_fold":"end:crashlog; fi; done || true
travis_fold:end:after_failure.4
travis_fold:start:after_failure.5
travis_time:start:383c0220
travis_time:start:383c0220
$ cat ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers || true
cat: ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers: No such file or directory
travis_fold:end:after_failure.5
travis_fold:start:after_failure.6
travis_time:start:2f34c2f1
$ dmesg | grep -i kill

I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact @TimNN. (Feature Requests)

@kennytm

This comment has been minimized.

Show comment
Hide comment
@kennytm

kennytm Sep 6, 2018

Member

@bors r-

Tidy failed.

Member

kennytm commented Sep 6, 2018

@bors r-

Tidy failed.

@withoutboats

This comment has been minimized.

Show comment
Hide comment
@withoutboats

withoutboats Sep 6, 2018

Contributor

@bors r=RalfJung

Contributor

withoutboats commented Sep 6, 2018

@bors r=RalfJung

@bors

This comment has been minimized.

Show comment
Hide comment
@bors

bors Sep 6, 2018

Contributor

📌 Commit 972cd8b has been approved by RalfJung

Contributor

bors commented Sep 6, 2018

📌 Commit 972cd8b has been approved by RalfJung

@kennytm

This comment has been minimized.

Show comment
Hide comment
@kennytm

kennytm Sep 7, 2018

Member

@bors rollup

Member

kennytm commented Sep 7, 2018

@bors rollup

kennytm added a commit to kennytm/rust that referenced this pull request Sep 7, 2018

Rollup merge of #53874 - withoutboats:pin-ptr-impls, r=RalfJung
Implement Unpin for Box, Rc, and Arc

Per the discussion in #49150, these should implement `Unpin` even if what they point to does not.

bors added a commit that referenced this pull request Sep 7, 2018

Auto merge of #54021 - kennytm:rollup, r=kennytm
Rollup of 19 pull requests

Successful merges:

 - #53162 (rustdoc: collect trait impls as an early pass)
 - #53299 (Updated core/macros.rs to note it works in a no_std environment.)
 - #53376 (Cross reference io::copy and fs::copy in docs.)
 - #53455 (Individual docs for {from,to}_*_bytes)
 - #53522 (Add doc for impl From for Addr)
 - #53550 (librustc_lint: In recursion warning, change 'recurring' to 'recursing')
 - #53860 (Migrate (some) of run-pass/ to ui)
 - #53874 (Implement Unpin for Box, Rc, and Arc)
 - #53895 (tidy: Cleanups and clippy warning fixes)
 - #53935 (Update Cargo)
 - #53946 (Clarify `ManuallyDrop` docs)
 - #53948 (Minimized clippy test from when NLL disabled two-phase borrows)
 - #53959 (Add .git extension to submodule paths missing it)
 - #53966 (A few cleanups and minor improvements to mir/dataflow)
 - #53967 (propagate build.python into cmake)
 - #53979 (Remove `#[repr(transparent)]` from atomics)
 - #53991 (Add unchecked_shl/shr check for intrinsics to fix miri's test suit)
 - #53992 (migrate run-pass/borrowck to ui/run-pass)
 - #53994 (migrate run-pass/*/ to ui/run-pass)

Failed merges:

 - #53987 (rustbuild: allow configuring llvm version suffix)

r? @ghost

kennytm added a commit to kennytm/rust that referenced this pull request Sep 7, 2018

Rollup merge of #53874 - withoutboats:pin-ptr-impls, r=RalfJung
Implement Unpin for Box, Rc, and Arc

Per the discussion in #49150, these should implement `Unpin` even if what they point to does not.

bors added a commit that referenced this pull request Sep 7, 2018

Auto merge of #54021 - kennytm:rollup, r=kennytm
Rollup of 18 pull requests

Successful merges:

 - #53299 (Updated core/macros.rs to note it works in a no_std environment.)
 - #53376 (Cross reference io::copy and fs::copy in docs.)
 - #53455 (Individual docs for {from,to}_*_bytes)
 - #53550 (librustc_lint: In recursion warning, change 'recurring' to 'recursing')
 - #53830 (Add help message for missing IndexMut impl with NLL)
 - #53860 (Migrate (some) of run-pass/ to ui)
 - #53874 (Implement Unpin for Box, Rc, and Arc)
 - #53895 (tidy: Cleanups and clippy warning fixes)
 - #53935 (Update Cargo)
 - #53946 (Clarify `ManuallyDrop` docs)
 - #53948 (Minimized clippy test from when NLL disabled two-phase borrows)
 - #53959 (Add .git extension to submodule paths missing it)
 - #53966 (A few cleanups and minor improvements to mir/dataflow)
 - #53967 (propagate build.python into cmake)
 - #53979 (Remove `#[repr(transparent)]` from atomics)
 - #53991 (Add unchecked_shl/shr check for intrinsics to fix miri's test suit)
 - #53992 (migrate run-pass/borrowck to ui/run-pass)
 - #53994 (migrate run-pass/*/ to ui/run-pass)

bors added a commit that referenced this pull request Sep 7, 2018

Auto merge of #54021 - kennytm:rollup, r=kennytm
Rollup of 17 pull requests

Successful merges:

 - #53299 (Updated core/macros.rs to note it works in a no_std environment.)
 - #53376 (Cross reference io::copy and fs::copy in docs.)
 - #53455 (Individual docs for {from,to}_*_bytes)
 - #53550 (librustc_lint: In recursion warning, change 'recurring' to 'recursing')
 - #53860 (Migrate (some) of run-pass/ to ui)
 - #53874 (Implement Unpin for Box, Rc, and Arc)
 - #53895 (tidy: Cleanups and clippy warning fixes)
 - #53946 (Clarify `ManuallyDrop` docs)
 - #53948 (Minimized clippy test from when NLL disabled two-phase borrows)
 - #53959 (Add .git extension to submodule paths missing it)
 - #53966 (A few cleanups and minor improvements to mir/dataflow)
 - #53967 (propagate build.python into cmake)
 - #53979 (Remove `#[repr(transparent)]` from atomics)
 - #53991 (Add unchecked_shl/shr check for intrinsics to fix miri's test suit)
 - #53992 (migrate run-pass/borrowck to ui/run-pass)
 - #53994 (migrate run-pass/*/ to ui/run-pass)
 - #54023 (update clippy submodule)

@bors bors merged commit 972cd8b into rust-lang:master Sep 7, 2018

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment