--enable-warnings-as-errors fails due to -D deprecated with Rust 1.38
Categories
(Core :: Graphics: WebRender, defect, P3)
Tracking
()
Tracking | Status | |
---|---|---|
firefox69 | --- | affected |
People
(Reporter: jbeich, Unassigned)
Details
Regressed by https://github.com/rust-lang/rust/pull/60445
$ rustc -vV
rustc 1.38.0-nightly
binary: rustc
commit-hash: 481068a70767
commit-date: 2019-07-05
host: x86_64-unknown-freebsd
release: 1.38.0-nightly
LLVM version: 8.0
$ echo "ac_add_options --enable-warnings-as-errors" >>.mozconfig
$ ./mach build
[...]
error: use of deprecated item 'std::mem::uninitialized': use `mem::MaybeUninit` instead
--> gfx/wr/webrender/src/prim_store/gradient.rs:665:77
|
665 | let mut entries: [GradientDataEntry; GRADIENT_DATA_SIZE] = unsafe { mem::uninitialized() };
| ^^^^^^^^^^^^^^^^^^
|
= note: `-D deprecated` implied by `-D warnings`
error: use of deprecated item 'std::mem::uninitialized': use `mem::MaybeUninit` instead
--> gfx/wr/webrender/src/renderer.rs:1467:32
|
1467 | data.push(unsafe { mem::uninitialized() });
| ^^^^^^^^^^^^^^^^^^
error: use of deprecated item 'std::mem::uninitialized': use `mem::MaybeUninit` instead
--> gfx/wr/webrender/src/renderer.rs:1475:36
|
1475 | data.push(unsafe { mem::uninitialized() });
| ^^^^^^^^^^^^^^^^^^
error: use of deprecated item 'std::mem::uninitialized': use `mem::MaybeUninit` instead
--> gfx/wr/webrender/src/platform/unix/font.rs:546:42
|
546 | let mut cbox: FT_BBox = unsafe { mem::uninitialized() };
| ^^^^^^^^^^^^^^^^^^
error: use of deprecated item 'std::mem::uninitialized': use `mem::MaybeUninit` instead
--> gfx/wr/webrender/src/platform/unix/font.rs:729:37
|
729 | let mut cbox: FT_BBox = mem::uninitialized();
| ^^^^^^^^^^^^^^^^^^
error: aborting due to 5 previous errors
error: Could not compile `webrender`.
Comment 1•5 years ago
|
||
Trying to use MaybeUninit on non-nightly rust I get told not to use an unstable library feature. So this will probably have to wait to be fixed.
Comment 2•5 years ago
|
||
Looks like Simon has patches for this. According to https://bugzilla.mozilla.org/show_bug.cgi?id=1563623#c0 1.36 stable has support for MaybeUninit, so maybe you need to bump your stable version?
Comment 3•5 years ago
|
||
(In reply to Kartikaya Gupta (email:kats@mozilla.com) (away 17-Jul-2019 to Feb-2020) from comment #2)
Looks like Simon has patches for this. According to
https://bugzilla.mozilla.org/show_bug.cgi?id=1563623#c0 1.36 stable has
support for MaybeUninit, so maybe you need to bump your stable version?*** This bug has been marked as a duplicate of bug 1564873 ***
I'm on 1.35, I did a mach bootstrap immediately before. So either 1.35 is still above the minimum required or there is a bug somewhere.
Comment 4•5 years ago
|
||
(In reply to Timothy Nikkel (:tnikkel) from comment #3)
I'm on 1.35, I did a mach bootstrap immediately before. So either 1.35 is
still above the minimum required or there is a bug somewhere.
Bug 1564873 is dependent on bug 1565193 which is to bump rust requirements from 1.35 to 1.36, so that explains it.
Description
•