Closed Bug 1556510 Opened 5 years ago Closed 5 years ago

--enable-warnings-as-errors fails due to -D bare-trait-objects with Rust 1.37

Categories

(Core :: JavaScript: WebAssembly, task)

task
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla69
Tracking Status
firefox69 --- fixed

People

(Reporter: jbeich, Assigned: bbouvier)

References

Details

Attachments

(1 file)

$ rustc -vV
rustc 1.37.0-nightly
binary: rustc
commit-hash: 7840a0b753a0
commit-date: 2019-05-31
host: x86_64-unknown-freebsd
release: 1.37.0-nightly
LLVM version: 8.0

$ echo "ac_add_options --enable-warnings-as-errors" >>.mozconfig
$ ./mach build
[...]
error: trait objects without an explicit dyn are deprecated
--> js/src/wasm/cranelift/src/compile.rs:74:14
|
74 | isa: Box<TargetIsa>,
| ^^^^^^^^^ help: use dyn: dyn TargetIsa
|
= note: -D bare-trait-objects implied by -D warnings
error: trait objects without an explicit dyn are deprecated
--> js/src/wasm/cranelift/src/cpu.rs:50:60
|
50 | pub fn make_isa(env: &StaticEnvironment) -> DashResult<Box<isa::TargetIsa>> {
| ^^^^^^^^^^^^^^ help: use dyn: dyn isa::TargetIsa
error: trait objects without an explicit dyn are deprecated
--> js/src/wasm/cranelift/src/utils.rs:22:22
|
22 | type DashError = Box<error::Error>;
| ^^^^^^^^^^^^ help: use dyn: dyn error::Error
error: trait objects without an explicit dyn are deprecated
--> js/src/wasm/cranelift/src/wasm2clif.rs:110:14
|
110 | isa: &'a TargetIsa,
| ^^^^^^^^^ help: use dyn: dyn TargetIsa
error: trait objects without an explicit dyn are deprecated
--> js/src/wasm/cranelift/src/wasm2clif.rs:158:18
|
158 | isa: &'a TargetIsa,
| ^^^^^^^^^ help: use dyn: dyn TargetIsa
error: aborting due to 5 previous errors
error: Could not compile baldrdash.

Probably regressed by https://github.com/rust-lang/rust/pull/61203 which was merged into Nightly on 2019-05-29.

See Also: → 1556597
See Also: → 1556598
See Also: → 1556602

Thanks Jan for opening an issue! This patch makes it work with both stable and nightly, and applies rustfmt on the directory.

Assignee: nobody → bbouvier
Status: NEW → ASSIGNED
Type: defect → task
Pushed by bbouvier@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/d21afff8a594
Mark trait objects with dyn in the wasm/cranelift directory; r=lth
Status: ASSIGNED → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla69
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: