mirror of
https://github.com/trezor/trezor-firmware.git
synced 2024-11-16 04:29:08 +00:00
Revert "chore(core/rust): remove useless unsafe block"
This reverts commit f8dc17d028
.
This commit is contained in:
parent
da82102281
commit
b1f1ed23b7
@ -131,7 +131,7 @@ impl TryFrom<Obj> for Gc<List> {
|
||||
type Error = Error;
|
||||
|
||||
fn try_from(value: Obj) -> Result<Self, Self::Error> {
|
||||
if ffi::mp_type_list.is_type_of(value) {
|
||||
if unsafe { ffi::mp_type_list.is_type_of(value) } {
|
||||
// SAFETY: We assume that if `value` is an object pointer with the correct type,
|
||||
// it is managed by MicroPython GC (see `Gc::from_raw` for details).
|
||||
let this = unsafe { Gc::from_raw(value.as_ptr().cast()) };
|
||||
|
Loading…
Reference in New Issue
Block a user