mirror of
https://github.com/isar/rusqlite.git
synced 2025-08-20 21:09:31 +08:00
clippy:ptr_as_ptr
This commit is contained in:
@@ -228,7 +228,7 @@ impl<'a> ValueRef<'a> {
|
||||
!text.is_null(),
|
||||
"unexpected SQLITE_TEXT value type with NULL data"
|
||||
);
|
||||
let s = from_raw_parts(text as *const u8, len as usize);
|
||||
let s = from_raw_parts(text.cast::<u8>(), len as usize);
|
||||
ValueRef::Text(s)
|
||||
}
|
||||
ffi::SQLITE_BLOB => {
|
||||
@@ -246,7 +246,7 @@ impl<'a> ValueRef<'a> {
|
||||
!blob.is_null(),
|
||||
"unexpected SQLITE_BLOB value type with NULL data"
|
||||
);
|
||||
ValueRef::Blob(from_raw_parts(blob as *const u8, len as usize))
|
||||
ValueRef::Blob(from_raw_parts(blob.cast::<u8>(), len as usize))
|
||||
} else {
|
||||
// The return value from sqlite3_value_blob() for a zero-length BLOB
|
||||
// is a NULL pointer.
|
||||
|
Reference in New Issue
Block a user