-
Notifications
You must be signed in to change notification settings - Fork 58
Closed
Labels
Description
af::add is throwing a convertible error if you pass in an &af::Array
let test2 = add(&a, &b).unwrap();➜ arrayfire-rust git:(master) ✗ cargo run --example helloworld
Compiling arrayfire v3.0.0 (file:///Users/jramapuram/projects/arrayfire-rust)
examples/helloworld.rs:39:17: 39:20 error: the trait `arrayfire::arith::Convertable` is not implemented for the type `&arrayfire::array::Array` [E0277]
examples/helloworld.rs:39 let test2 = add(&a, &b).unwrap();
^~~
examples/helloworld.rs:39:17: 39:20 help: run `rustc --explain E0277` to see a detailed explanation
examples/helloworld.rs:39:17: 39:20 error: the trait `arrayfire::arith::Convertable` is not implemented for the type `&arrayfire::array::Array` [E0277]
examples/helloworld.rs:39 let test2 = add(&a, &b).unwrap();
^~~
examples/helloworld.rs:39:17: 39:20 help: run `rustc --explain E0277` to see a detailed explanation
error: aborting due to 2 previous errors
Could not compile `arrayfire`.However, operator+ seems to work just fine. This behaviour should be consistent & accept an &Array.