You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Trying to build with features glfw-sys, raw-window-handle-v0-6 and wayland and getting the following error:
Screenshot with highlighting
Error
error[E0061]: this function takes 1 argument but 2 arguments were supplied
--> /home/RDuhen/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glfw-0.56.0/src/lib.rs:3689:22
|
3689 | let handle = WaylandDisplayHandle::new(display,0);
| ^^^^^^^^^^^^^^^^^^^^^^^^^ - unexpected argument of type `{integer}`
|
note: expected `NonNull<c_void>`, found `Option<NonNull<c_void>>`
--> /home/RDuhen/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glfw-0.56.0/src/lib.rs:3689:48
|
3689 | let handle = WaylandDisplayHandle::new(display,0);
| ^^^^^^^
= note:expected struct `NonNull<_>`
found enum `Option<NonNull<_>>`
note: associated function defined here
--> /home/RDuhen/.cargo/registry/src/index.crates.io-6f17d22bba15001f/raw-window-handle-0.6.2/src/unix.rs:176:12
|
176 | pub fn new(display:NonNull<c_void>) -> Self{
| ^^^
help: consider using `Option::expect` to unwrap the `Option<NonNull<c_void>>` value, panicking if the value is an `Option::None`
|
3689 | let handle = WaylandDisplayHandle::new(display.expect("REASON"),0);
| +++++++++++++++++
help: remove the extra argument
|
3689 - let handle = WaylandDisplayHandle::new(display,0);3689 + let handle = WaylandDisplayHandle::new(/* NonNull<c_void> */);
|
The fix is simple but after looking at the documentation for raw-window-handle I couldn't find a single version where the WaylandDisplayHandle::new function took 2 arguments, is there a special reason why it does here?
The text was updated successfully, but these errors were encountered:
Trying to build with features
glfw-sys
,raw-window-handle-v0-6
andwayland
and getting the following error:Screenshot with highlighting
Error
The fix is simple but after looking at the documentation for
raw-window-handle
I couldn't find a single version where theWaylandDisplayHandle::new
function took 2 arguments, is there a special reason why it does here?The text was updated successfully, but these errors were encountered: