Skip to content

Commit

Permalink
Fix lint failure (#59)
Browse files Browse the repository at this point in the history
fix #58

error: casting raw pointers to the same type and constness is
unnecessary (`*mut capi::DFArrowArray` -> `*mut capi::DFArrowArray`)
       --> src/capi.rs:651:21
        |
651 | (*c_abi_record_batch as *mut DFArrowArray) as *mut FFI_ArrowArray,
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try:
`*c_abi_record_batch`
        |
= help: for further information visit
https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast
= note: `-D clippy::unnecessary-cast` implied by `-D clippy::all`
  • Loading branch information
kou committed Sep 11, 2023
1 parent b7d3ed0 commit 99c2d7f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/capi.rs
Original file line number Diff line number Diff line change
Expand Up @@ -648,7 +648,7 @@ pub extern "C" fn df_session_context_register_record_batches(
for c_abi_record_batch in c_abi_record_batch_slice {
let rs_ffi_record_batch = unsafe {
std::ptr::replace(
(*c_abi_record_batch as *mut DFArrowArray) as *mut FFI_ArrowArray,
*c_abi_record_batch as *mut FFI_ArrowArray,
FFI_ArrowArray::empty(),
)
};
Expand Down

0 comments on commit 99c2d7f

Please sign in to comment.