Skip to content

Commit

Permalink
fix incorrect pointer type and fix unused use
Browse files Browse the repository at this point in the history
  • Loading branch information
gerwin3 committed Aug 14, 2023
1 parent 4ff6b46 commit 69cfa92
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 3 deletions.
2 changes: 1 addition & 1 deletion src/ffi/device.rs
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ impl Device {
let mut id: i32 = 0;
let id_ptr = std::ptr::addr_of_mut!(id);
let ret = cpp!(unsafe [
id_ptr as "int"
id_ptr as "int*"
] -> i32 as "int" {
return cudaGetDevice(id_ptr);
});
Expand Down
2 changes: 0 additions & 2 deletions src/ffi/ptr.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
use crate::device::DeviceId;

/// Represents a device-local pointer. Pointers qualify as device-local if they refer to memory that
/// lives on the device, and not on the host.
///
Expand Down

0 comments on commit 69cfa92

Please sign in to comment.