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

CTFE: simplify ConstValue by not checking for alignment #63079

Merged
merged 5 commits into from Aug 5, 2019

Conversation

@RalfJung
Copy link
Member

commented Jul 28, 2019

I hope the test suite actually covers the problematic cases here?

r? @oli-obk

Fixes #61952

@RalfJung RalfJung changed the title CTFE: simplify Value type by not checking for alignment CTFE: simplify ConstValue by not checking for alignment Jul 28, 2019

@rust-highfive

This comment was marked as resolved.

Copy link
Collaborator

commented Jul 28, 2019

The job x86_64-gnu-llvm-6.0 of your PR failed (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.
2019-07-28T12:02:14.7805937Z ##[command]git remote add origin https://github.com/rust-lang/rust
2019-07-28T12:02:14.7985645Z ##[command]git config gc.auto 0
2019-07-28T12:02:14.8043493Z ##[command]git config --get-all http.https://github.com/rust-lang/rust.extraheader
2019-07-28T12:02:14.8097593Z ##[command]git config --get-all http.proxy
2019-07-28T12:02:14.8211674Z ##[command]git -c http.extraheader="AUTHORIZATION: basic ***" fetch --force --tags --prune --progress --no-recurse-submodules --depth=2 origin +refs/heads/*:refs/remotes/origin/* +refs/pull/63079/merge:refs/remotes/pull/63079/merge
---
2019-07-28T12:02:47.3925305Z do so (now or later) by using -b with the checkout command again. Example:
2019-07-28T12:02:47.3926549Z 
2019-07-28T12:02:47.3928295Z   git checkout -b <new-branch-name>
2019-07-28T12:02:47.3930252Z 
2019-07-28T12:02:47.3932023Z HEAD is now at af6e69129 Merge 4063bc1194f2b7151cfdb2df3979d31fd18ed10a into 9a239ef4ded03d155c72b68b5a2dd7aff013e141
2019-07-28T12:02:47.4078225Z ##[section]Starting: Collect CPU-usage statistics in the background
2019-07-28T12:02:47.4081424Z ==============================================================================
2019-07-28T12:02:47.4081502Z Task         : Bash
2019-07-28T12:02:47.4081550Z Description  : Run a Bash script on macOS, Linux, or Windows
---
2019-07-28T12:58:19.3334003Z .........................................F.......................................................... 1400/8798
2019-07-28T12:58:24.6007652Z .................................................................................................... 1500/8798
2019-07-28T12:58:35.9722837Z .............................................................i...............i...................... 1600/8798
2019-07-28T12:58:42.8926343Z .................................................................................................... 1700/8798
2019-07-28T12:58:56.1942944Z ...............................................iiiii................................................ 1800/8798
2019-07-28T12:59:06.3915279Z .................................................................................................... 2000/8798
2019-07-28T12:59:08.6370991Z .................................................................................................... 2100/8798
2019-07-28T12:59:12.1179596Z .................................................................................................... 2200/8798
2019-07-28T12:59:18.1776783Z .................................................................................................... 2300/8798
---
2019-07-28T13:02:41.9900723Z .................................................................................................... 5200/8798
2019-07-28T13:02:52.1414375Z ...................................................................................................i 5300/8798
2019-07-28T13:02:59.6196308Z .................................................................................................... 5400/8798
2019-07-28T13:03:04.2751217Z .................................................................................................... 5500/8798
2019-07-28T13:03:15.1124135Z ............................................................................................ii...i.. 5600/8798
2019-07-28T13:03:29.4147728Z ii...........i...................................................................................... 5700/8798
2019-07-28T13:03:40.9606411Z .................................................................................................... 5900/8798
2019-07-28T13:03:40.9606411Z .................................................................................................... 5900/8798
2019-07-28T13:03:45.0832283Z ............................................................................................i..ii... 6000/8798
2019-07-28T13:04:12.9531517Z .................................................................................................... 6200/8798
2019-07-28T13:04:14.8107726Z ...................................i................................................................ 6300/8798
2019-07-28T13:04:16.6632954Z .................................................................................................... 6400/8798
2019-07-28T13:04:18.6679140Z ....i............................................................................................... 6500/8798
---
2019-07-28T13:07:55.9737306Z 1 error[E0080]: it is undefined behavior to use this value
2019-07-28T13:07:55.9737601Z -   --> $DIR/ub-ref.rs:9:1
2019-07-28T13:07:55.9737915Z +   --> $DIR/ub-ref.rs:8:1
2019-07-28T13:07:55.9738090Z 3    |
2019-07-28T13:07:55.9738209Z 4 LL | const NULL: &u16 = unsafe { mem::transmute(0usize) };
2019-07-28T13:07:55.9738336Z 5    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ type validation failed: encountered 0, but expected something greater or equal to 1
2019-07-28T13:07:55.9738462Z 
2019-07-28T13:07:55.9739062Z 7    = note: The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior
2019-07-28T13:07:55.9739368Z 9 error[E0080]: it is undefined behavior to use this value
2019-07-28T13:07:55.9739652Z -   --> $DIR/ub-ref.rs:12:1
2019-07-28T13:07:55.9739976Z +   --> $DIR/ub-ref.rs:11:1
2019-07-28T13:07:55.9740123Z 11    |
2019-07-28T13:07:55.9740123Z 11    |
2019-07-28T13:07:55.9740241Z 12 LL | const REF_AS_USIZE: usize = unsafe { mem::transmute(&0) };
2019-07-28T13:07:55.9740830Z 13    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ type validation failed: encountered a pointer, but expected initialized plain (non-pointer) bytes
2019-07-28T13:07:55.9740981Z 
2019-07-28T13:07:55.9741443Z 15    = note: The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior
2019-07-28T13:07:55.9741758Z 17 error[E0080]: it is undefined behavior to use this value
2019-07-28T13:07:55.9742040Z -   --> $DIR/ub-ref.rs:15:1
2019-07-28T13:07:55.9743113Z +   --> $DIR/ub-ref.rs:14:1
2019-07-28T13:07:55.9743365Z 19    |
2019-07-28T13:07:55.9743365Z 19    |
2019-07-28T13:07:55.9743511Z 20 LL | const REF_AS_USIZE_SLICE: &[usize] = &[unsafe { mem::transmute(&0) }];
2019-07-28T13:07:55.9744020Z 21    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ type validation failed: encountered a pointer at .<deref>, but expected plain (non-pointer) bytes
2019-07-28T13:07:55.9744388Z 
2019-07-28T13:07:55.9745000Z 23    = note: The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior
2019-07-28T13:07:55.9745469Z 25 error[E0080]: it is undefined behavior to use this value
2019-07-28T13:07:55.9746247Z -   --> $DIR/ub-ref.rs:18:1
2019-07-28T13:07:55.9746678Z +   --> $DIR/ub-ref.rs:17:1
2019-07-28T13:07:55.9747774Z 27    |
2019-07-28T13:07:55.9747774Z 27    |
2019-07-28T13:07:55.9748083Z 28 LL | const USIZE_AS_REF: &'static u8 = unsafe { mem::transmute(1337usize) };
2019-07-28T13:07:55.9748257Z 29    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ type validation failed: encountered dangling reference (created from integer)
2019-07-28T13:07:55.9748343Z 
2019-07-28T13:07:55.9748381Z The actual stderr differed from the expected stderr.
2019-07-28T13:07:55.9748664Z Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/consts/const-eval/ub-ref/ub-ref.stderr
2019-07-28T13:07:55.9748664Z Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/consts/const-eval/ub-ref/ub-ref.stderr
2019-07-28T13:07:55.9748888Z To update references, rerun the tests and pass the `--bless` flag
2019-07-28T13:07:55.9749102Z To only update this specific test, also pass `--test-args consts/const-eval/ub-ref.rs`
2019-07-28T13:07:55.9749169Z error: 1 errors occurred comparing output.
2019-07-28T13:07:55.9749224Z status: exit code: 1
2019-07-28T13:07:55.9749224Z status: exit code: 1
2019-07-28T13:07:55.9749833Z command: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "/checkout/src/test/ui/consts/const-eval/ub-ref.rs" "-Zthreads=1" "--target=x86_64-unknown-linux-gnu" "--error-format" "json" "-Zui-testing" "-C" "prefer-dynamic" "--out-dir" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/consts/const-eval/ub-ref" "-Crpath" "-O" "-Cdebuginfo=0" "-Zunstable-options" "-Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "-L" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/consts/const-eval/ub-ref/auxiliary" "-A" "unused"
2019-07-28T13:07:55.9750107Z ------------------------------------------
2019-07-28T13:07:55.9750135Z 
2019-07-28T13:07:55.9750326Z ------------------------------------------
2019-07-28T13:07:55.9750364Z stderr:
2019-07-28T13:07:55.9750364Z stderr:
2019-07-28T13:07:55.9750533Z ------------------------------------------
2019-07-28T13:07:55.9750592Z error[E0080]: it is undefined behavior to use this value
2019-07-28T13:07:55.9750794Z   --> /checkout/src/test/ui/consts/const-eval/ub-ref.rs:8:1
2019-07-28T13:07:55.9750837Z    |
2019-07-28T13:07:55.9750892Z LL | const NULL: &u16 = unsafe { mem::transmute(0usize) };
2019-07-28T13:07:55.9751104Z    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ type validation failed: encountered 0, but expected something greater or equal to 1
2019-07-28T13:07:55.9751149Z    |
2019-07-28T13:07:55.9751486Z    = note: The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior
2019-07-28T13:07:55.9751564Z error[E0080]: it is undefined behavior to use this value
2019-07-28T13:07:55.9751771Z   --> /checkout/src/test/ui/consts/const-eval/ub-ref.rs:11:1
2019-07-28T13:07:55.9751812Z    |
2019-07-28T13:07:55.9751812Z    |
2019-07-28T13:07:55.9751852Z LL | const REF_AS_USIZE: usize = unsafe { mem::transmute(&0) };
2019-07-28T13:07:55.9752135Z    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ type validation failed: encountered a pointer, but expected initialized plain (non-pointer) bytes
2019-07-28T13:07:55.9752526Z    |
2019-07-28T13:07:55.9752989Z    = note: The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior
2019-07-28T13:07:55.9753085Z error[E0080]: it is undefined behavior to use this value
2019-07-28T13:07:55.9753435Z   --> /checkout/src/test/ui/consts/const-eval/ub-ref.rs:14:1
2019-07-28T13:07:55.9753500Z    |
2019-07-28T13:07:55.9753500Z    |
2019-07-28T13:07:55.9753551Z LL | const REF_AS_USIZE_SLICE: &[usize] = &[unsafe { mem::transmute(&0) }];
2019-07-28T13:07:55.9753943Z    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ type validation failed: encountered a pointer at .<deref>, but expected plain (non-pointer) bytes
2019-07-28T13:07:55.9754001Z    |
2019-07-28T13:07:55.9754381Z    = note: The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior
2019-07-28T13:07:55.9754571Z error[E0080]: it is undefined behavior to use this value
2019-07-28T13:07:55.9754829Z   --> /checkout/src/test/ui/consts/const-eval/ub-ref.rs:17:1
2019-07-28T13:07:55.9754900Z    |
2019-07-28T13:07:55.9754900Z    |
2019-07-28T13:07:55.9755151Z LL | const USIZE_AS_REF: &'static u8 = unsafe { mem::transmute(1337usize) };
2019-07-28T13:07:55.9755219Z    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ type validation failed: encountered dangling reference (created from integer)
2019-07-28T13:07:55.9755289Z    |
2019-07-28T13:07:55.9755671Z    = note: The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior
2019-07-28T13:07:55.9755934Z error: aborting due to 4 previous errors
2019-07-28T13:07:55.9755957Z 
2019-07-28T13:07:55.9756138Z For more information about this error, try `rustc --explain E0080`.
2019-07-28T13:07:55.9756189Z 
---
2019-07-28T13:07:55.9771631Z thread 'main' panicked at 'Some tests failed', src/tools/compiletest/src/main.rs:534:22
2019-07-28T13:07:55.9771707Z note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace.
2019-07-28T13:07:55.9791065Z 
2019-07-28T13:07:55.9791202Z 
2019-07-28T13:07:55.9793719Z command did not execute successfully: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage0-tools-bin/compiletest" "--compile-lib-path" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/lib" "--run-lib-path" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/lib/rustlib/x86_64-unknown-linux-gnu/lib" "--rustc-path" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "--src-base" "/checkout/src/test/ui" "--build-base" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui" "--stage-id" "stage2-x86_64-unknown-linux-gnu" "--mode" "ui" "--target" "x86_64-unknown-linux-gnu" "--host" "x86_64-unknown-linux-gnu" "--llvm-filecheck" "/usr/lib/llvm-6.0/bin/FileCheck" "--host-rustcflags" "-Crpath -O -Cdebuginfo=0 -Zunstable-options  -Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "--target-rustcflags" "-Crpath -O -Cdebuginfo=0 -Zunstable-options  -Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "--docck-python" "/usr/bin/python2.7" "--lldb-python" "/usr/bin/python2.7" "--gdb" "/usr/bin/gdb" "--quiet" "--llvm-version" "6.0.0\n" "--system-llvm" "--cc" "" "--cxx" "" "--cflags" "" "--llvm-components" "" "--llvm-cxxflags" "" "--adb-path" "adb" "--adb-test-dir" "/data/tmp/work" "--android-cross-path" "" "--color" "always"
2019-07-28T13:07:55.9794201Z 
2019-07-28T13:07:55.9794322Z 
2019-07-28T13:07:55.9798260Z failed to run: /checkout/obj/build/bootstrap/debug/bootstrap test
2019-07-28T13:07:55.9798944Z Build completed unsuccessfully in 0:59:03
2019-07-28T13:07:55.9798944Z Build completed unsuccessfully in 0:59:03
2019-07-28T13:07:56.7363896Z ##[error]Bash exited with code '1'.
2019-07-28T13:07:56.7398499Z ##[section]Starting: Checkout
2019-07-28T13:07:56.7399893Z ==============================================================================
2019-07-28T13:07:56.7399933Z Task         : Get sources
2019-07-28T13:07:56.7399984Z Description  : Get sources from a repository. Supports Git, TfsVC, and SVN repositories.

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)

@oli-obk

This comment has been minimized.

Copy link
Contributor

commented Jul 28, 2019

What do you think about removing the align field of Mplace in const eval by making it an assoc type of the Engine?

@RalfJung RalfJung force-pushed the RalfJung:ctfe-no-align branch from 4063bc1 to c237ed8 Jul 28, 2019

@RalfJung

This comment has been minimized.

Copy link
Member Author

commented Jul 28, 2019

What do you think about removing the align field of Mplace in const eval by making it an assoc type of the Engine?

Hm. Not sure how well that code would factor.

With #63075, we actually don't need the align field in places any more. However, my expectation is that for raw pointers we might eventually want to relax the rule that says "when you do *ptr, even if you are just computing a field offset, the ptr must be aligned and dereferencable". So I am reluctant to remove all that infrastructure if we have to bring it back later.

@oli-obk

This comment has been minimized.

Copy link
Contributor

commented Jul 28, 2019

I don't want to remove the field. Miri will keep using it. Const eval doesn't need it though. If you do UB in const eval, we don't promise we catch it.

@oli-obk

This comment has been minimized.

Copy link
Contributor

commented Jul 28, 2019

We should probably find a way to make miri's const_eval query run with all miri-checks on.

@RalfJung

This comment has been minimized.

Copy link
Member Author

commented Jul 28, 2019

Miri will keep using it.

With #63075 the field is effectively dead in Miri, though. For now. I think.

@oli-obk

This comment has been minimized.

Copy link
Contributor

commented Jul 28, 2019

Ah, ok. We can revisit once that is resolved then. Can you make sure that it's documented $somewhere in the process, so that we actually do revisit?

r=me with travis green

@RalfJung

This comment has been minimized.

Copy link
Member Author

commented Jul 28, 2019

Const eval doesn't need it though.

Agreed. But factoring that through the Machine trait will be somewhat messy: MPlaceTy and PlaceTy would get another generic parameter; and the check_ptr_access method in Memory would end up split across both sides of the interface.

@RalfJung

This comment has been minimized.

Copy link
Member Author

commented Jul 28, 2019

@bors r=oli-obk

@bors

This comment has been minimized.

Copy link
Contributor

commented Jul 28, 2019

📌 Commit cfb13b0 has been approved by oli-obk

@bors

This comment has been minimized.

Copy link
Contributor

commented Jul 29, 2019

⌛️ Testing commit cfb13b0 with merge 4034b4c...

bors added a commit that referenced this pull request Jul 29, 2019
Auto merge of #63079 - RalfJung:ctfe-no-align, r=oli-obk
CTFE: simplify ConstValue by not checking for alignment

I hope the test suite actually covers the problematic cases here?

r? @oli-obk

Fixes #61952
@bors

This comment has been minimized.

Copy link
Contributor

commented Jul 29, 2019

💔 Test failed - checks-azure

@rust-highfive

This comment was marked as resolved.

Copy link
Collaborator

commented Jul 29, 2019

Your PR failed (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.
2019-07-29T10:12:11.0785010Z ==============================================================================
2019-07-29T10:12:11.2633420Z Generating script.
2019-07-29T10:12:11.2680420Z ========================== Starting Command Output ===========================
2019-07-29T10:12:11.2706170Z [command]/bin/bash --noprofile --norc /Users/vsts/agent/2.154.3/work/_temp/d763b023-8f12-400e-b0e7-49b93350127b.sh
2019-07-29T10:18:06.5302210Z error: RPC failed; curl 18 transfer closed with outstanding read data remaining
2019-07-29T10:18:06.5318420Z fatal: the remote end hung up unexpectedly
2019-07-29T10:18:06.5389450Z Error: Fetching /usr/local/Homebrew/Library/Taps/homebrew/homebrew-cask failed!
2019-07-29T10:18:11.8529650Z   https://github.com/Homebrew/brew#donations
2019-07-29T10:18:38.3050330Z Updated 2 taps (caskroom/versions and homebrew/core).
2019-07-29T10:18:38.3051650Z ==> New Formulae
2019-07-29T10:18:38.3052380Z asyncplusplus
---
2019-07-29T10:18:38.3183530Z ==> Deleted Formulae
2019-07-29T10:18:38.3183600Z libggz
2019-07-29T10:18:38.3183760Z libguess
2019-07-29T10:18:38.3183820Z lysp
2019-07-29T10:18:38.3555150Z ##[error]Bash exited with code '1'.
2019-07-29T10:18:38.3775940Z ##[section]Starting: Upload CPU usage statistics
2019-07-29T10:18:38.3780800Z ==============================================================================
2019-07-29T10:18:38.3780910Z Task         : Bash
2019-07-29T10:18:38.3781000Z Description  : Run a Bash script on macOS, Linux, or Windows
---
2019-07-29T10:18:38.5718160Z Script contents:
2019-07-29T10:18:38.5721790Z aws s3 cp --acl public-read cpu-usage.csv s3://$DEPLOY_BUCKET/rustc-builds/$BUILD_SOURCEVERSION/cpu-$SYSTEM_JOBNAME.csv
2019-07-29T10:18:38.5750850Z ========================== Starting Command Output ===========================
2019-07-29T10:18:38.5777900Z [command]/bin/bash --noprofile --norc /Users/vsts/agent/2.154.3/work/_temp/b49b91c1-74f7-4d5e-8510-fc861828ebd2.sh
2019-07-29T10:18:38.5899630Z /Users/vsts/agent/2.154.3/work/_temp/b49b91c1-74f7-4d5e-8510-fc861828ebd2.sh: line 1: aws: command not found
2019-07-29T10:18:38.5986310Z ##[error]Bash exited with code '127'.
2019-07-29T10:18:38.6030470Z ##[section]Starting: Checkout
2019-07-29T10:18:38.6033810Z ==============================================================================
2019-07-29T10:18:38.6033940Z Task         : Get sources
2019-07-29T10:18:38.6034120Z Description  : Get sources from a repository. Supports Git, TfsVC, and SVN repositories.

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)

@RalfJung

This comment has been minimized.

Copy link
Member Author

commented Jul 29, 2019

@oli-obk @Centril I made validity check alignment even when the machine does not. I am not very happy with check_ptr_access_align as method name though.

(Also that CI failure looks spurious.)

@bors

This comment was marked as resolved.

Copy link
Contributor

commented Aug 2, 2019

☔️ The latest upstream changes (presumably #63214) made this pull request unmergeable. Please resolve the merge conflicts.

@RalfJung RalfJung force-pushed the RalfJung:ctfe-no-align branch from a6846a9 to 0cf4329 Aug 2, 2019

@RalfJung

This comment has been minimized.

Copy link
Member Author

commented Aug 2, 2019

Rebased. @oli-obk what do you think of checking alignment in validity even when the machine otherwise ignores alignment (as is now implemented here)?

@oli-obk

This comment has been minimized.

Copy link
Contributor

commented Aug 5, 2019

I think it's very reasonable. We can always weaken validity checks if we need to. Hardening them is not easy to do.

@bors r+

@bors

This comment has been minimized.

Copy link
Contributor

commented Aug 5, 2019

📌 Commit 0cf4329 has been approved by oli-obk

@bors

This comment has been minimized.

Copy link
Contributor

commented Aug 5, 2019

⌛️ Testing commit 0cf4329 with merge 4be0675...

bors added a commit that referenced this pull request Aug 5, 2019
Auto merge of #63079 - RalfJung:ctfe-no-align, r=oli-obk
CTFE: simplify ConstValue by not checking for alignment

I hope the test suite actually covers the problematic cases here?

r? @oli-obk

Fixes #61952
@bors

This comment has been minimized.

Copy link
Contributor

commented Aug 5, 2019

☀️ Test successful - checks-azure
Approved by: oli-obk
Pushing 4be0675 to master...

@bors bors added the merged-by-bors label Aug 5, 2019

@bors bors merged commit 0cf4329 into rust-lang:master Aug 5, 2019

5 checks passed

homu Test successful
Details
pr Build #20190802.42 succeeded
Details
pr (Linux mingw-check) Linux mingw-check succeeded
Details
pr (Linux x86_64-gnu-llvm-6.0) Linux x86_64-gnu-llvm-6.0 succeeded
Details
pr (LinuxTools) LinuxTools succeeded
Details

@RalfJung RalfJung deleted the RalfJung:ctfe-no-align branch Aug 5, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
5 participants
You can’t perform that action at this time.