In one of my projects, I used pixel-canvas, which depends on glium which dependents on glutin which depends on winit which depends on objc. So, the dependency will be my_project->pixel_canvas->glium->glutin->winit->objc. When I try to compile my code using beta rustc on my MacBook Pro M1, there is a compile error(mismatched types) with winit due to the change of objc, and this error has been fixed in main branch of winit but not released.
Can I somehow change the Cargo.toml of my project to force the compiler to use the latest version of winit so to pass the compilation?
I have tried this in the Cargo.toml of my project and then done cargo update, but the problem remained unresolved.
A patch is only used when the version to which the crate would resolve to if there wasn't a patch matches the version as specified in the patched in crate. If this is not the case, there should be a warning and the patch is not used.
Oh, I'm not sure how to fix that, I thought adding the git dep would force cargo to pick the git dep, because it has the latest version. But maybe that only works with crates.io deps.