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
error[E0308]: arguments to this function are incorrect
--> src/v2/body.rs:20:5
|
20 | Aabb2::new(Point2::new(minx, miny), Point2::new(maxx, maxy))
| ^^^^^^^^^^
|
note: expected `cgmath::point::Point2<f32>`, found `Point2<f32>`
--> src/v2/body.rs:20:16
|
20 | Aabb2::new(Point2::new(minx, miny), Point2::new(maxx, maxy))
| ^^^^^^^^^^^^^^^^^^^^^^^
= note: `Point2<f32>` and `cgmath::point::Point2<f32>` have similar names, but are actually distinct types
note: `Point2<f32>` is defined in crate `cgmath`
--> /Users/fabian/.cargo/registry/src/index.crates.io-6f17d22bba15001f/cgmath-0.18.0/src/point.rs:50:1
|
50 | pub struct Point2<S> {
| ^^^^^^^^^^^^^^^^^^^^
note: `cgmath::point::Point2<f32>` is defined in crate `cgmath`
--> /Users/fabian/.cargo/registry/src/index.crates.io-6f17d22bba15001f/cgmath-0.17.0/src/point.rs:50:1
|
50 | pub struct Point2<S> {
| ^^^^^^^^^^^^^^^^^^^^
= note: perhaps two different versions of crate `cgmath` are being used?
note: expected `cgmath::point::Point2<f32>`, found `Point2<f32>`
--> src/v2/body.rs:20:41
|
20 | Aabb2::new(Point2::new(minx, miny), Point2::new(maxx, maxy))
| ^^^^^^^^^^^^^^^^^^^^^^^
= note: `Point2<f32>` and `cgmath::point::Point2<f32>` have similar names, but are actually distinct types
note: `Point2<f32>` is defined in crate `cgmath`
--> /Users/fabian/.cargo/registry/src/index.crates.io-6f17d22bba15001f/cgmath-0.18.0/src/point.rs:50:1
|
50 | pub struct Point2<S> {
| ^^^^^^^^^^^^^^^^^^^^
note: `cgmath::point::Point2<f32>` is defined in crate `cgmath`
--> /Users/fabian/.cargo/registry/src/index.crates.io-6f17d22bba15001f/cgmath-0.17.0/src/point.rs:50:1
|
50 | pub struct Point2<S> {
| ^^^^^^^^^^^^^^^^^^^^
= note: perhaps two different versions of crate `cgmath` are being used?
note: associated function defined here
--> /Users/fabian/.cargo/registry/src/index.crates.io-6f17d22bba15001f/collision-0.20.1/src/volume/aabb/aabb2.rs:26:12
|
26 | pub fn new(p1: Point2<S>, p2: Point2<S>) -> Aabb2<S> {
| ^^^
I've copied the Aabb2 code from here: https://github.com/rustgd/collision-rs/blob/master/benches/dbvt.rs
but in my project it gives me a compile error:
Here are the deps from my cargo.toml:
I notice when i do a
cargo build
it installs cgmath 0.18.0 and 0.17.0:so not sure if the problem is that or not. And I am not sure why 2 versions of cgmath is being installed.
The text was updated successfully, but these errors were encountered: