Build fails on latest nightly.
mooman219 opened this issue · 7 comments
mooman219 commented
Looks like the unstable heap API updated.
error[E0308]: mismatched types
--> C:\Users\Mooma\.cargo\registry\src\github.com-1ecc6299db9ec823\bounded-spsc-queue-0.2.0\src\lib.rs:262:26
|
262 | Heap.dealloc(self.buffer as *mut u8, layout);
| ^^^^^^^^^^^^^^^^^^^^^^ expected struct `std::ptr::NonNull`, found *-ptr
|
= note: expected type `std::ptr::NonNull<std::heap::Opaque>`
found type `*mut u8`
error[E0599]: no method named `oom` found for type `std::heap::Global` in the current scope
--> C:\Users\Mooma\.cargo\registry\src\github.com-1ecc6299db9ec823\bounded-spsc-queue-0.2.0\src\lib.rs:350:24
|
350 | Err(e) => Heap.oom(e),
| ^^^
error[E0605]: non-primitive cast: `std::ptr::NonNull<std::heap::Opaque>` as `*mut T`
--> C:\Users\Mooma\.cargo\registry\src\github.com-1ecc6299db9ec823\bounded-spsc-queue-0.2.0\src\lib.rs:349:20
|
349 | Ok(ptr) => ptr as *mut T,
| ^^^^^^^^^^^^^
|
= note: an `as` expression can only be used to convert between primitive types. Consider using the `From` trait
error: aborting due to 3 previous errors
Some errors occurred: E0308, E0599, E0605.
For more information about an error, try `rustc --explain E0308`.
error: Could not compile `bounded-spsc-queue`.
warning: build failed, waiting for other jobs to finish...
error: build failed
polyfractal commented
Beat me to the punch! Just tagged and published v0.3.0
:)
FallingSnow commented
Yup, failing on nightly again.
$ rustc -vV
rustc 1.28.0-nightly (2a0062974 2018-06-09)
binary: rustc
commit-hash: 2a0062974a5225847fc43d5522c4dc3718173fe5
commit-date: 2018-06-09
host: x86_64-unknown-linux-gnu
release: 1.28.0-nightly
LLVM version: 6.0
error[E0061]: this function takes 1 parameter but 0 parameters were supplied
--> /src/github.com-1ecc6299db9ec823/bounded-spsc-queue-0.3.0/src/lib.rs:351:19
|
351 | Err(_) => alloc::oom(),
| ^^^^^^^^^^^^ expected 1 parameter
error: aborting due to previous error
mooman219 commented
This is still relevant, nightly still breaks this.
polyfractal commented
Just merged #20, gonna let tests run then I'll tag a release. Thanks all for your patience, work has been a bear lately :)
polyfractal commented
Tagged, pushed and published v0.4.0. Thanks all for your patience, let me know if anything else breaks :)