diff options
| author | Oliver Schneider <git-spam-no-reply9815368754983@oli-obk.de> | 2016-03-10 14:20:53 +0100 |
|---|---|---|
| committer | Oliver Schneider <git-spam-no-reply9815368754983@oli-obk.de> | 2016-03-10 14:20:53 +0100 |
| commit | fcee002edfd1867ab49d9625de6c7907f484a7a9 (patch) | |
| tree | b05487a0ad4a6f76e54a251f951352177ed25815 /src/libstd/sys/unix/stack_overflow.rs | |
| parent | d4d6260ef1f21668194d4b3423d4b0b155e0b08e (diff) | |
| download | rust-fcee002edfd1867ab49d9625de6c7907f484a7a9.tar.gz rust-fcee002edfd1867ab49d9625de6c7907f484a7a9.zip | |
break enum variant discriminant inference in case of 32-bit
`assert_eq!(-9223372036854775808isize as u64, 0x8000000000000000);`
fails on 32 bit and succeeds on 64 bit. These commits don't change that behavior.
The following worked before my changes, because the discriminant was
always processed as `u64`.
Now it fails, because the discriminant of `Bu64` is now `0` instead of `-9223372036854775808`. This is more in line with the above assertion's code, since
`-9223372036854775808isize as u64` on 32 bit yielded `0`.
```rust
enum Eu64 {
Au64 = 0,
Bu64 = 0x8000_0000_0000_0000
}
```Diffstat (limited to 'src/libstd/sys/unix/stack_overflow.rs')
0 files changed, 0 insertions, 0 deletions
