]> git.bitcoin.ninja Git - rust-lightning/commitdiff
Fix unused return warning for 'transmute_copy'.
authorElias Rohrer <elias.rohrer@tu-berlin.de>
Tue, 18 Jan 2022 13:45:43 +0000 (14:45 +0100)
committerElias Rohrer <elias.rohrer@tu-berlin.de>
Tue, 18 Jan 2022 13:45:43 +0000 (14:45 +0100)
lightning-invoice/src/lib.rs

index 2164f1c530fccc6b30dbaa632a8087311a255fdd..b6abecf3256d7a6c580e6e5cfe40594fc899b96c 100644 (file)
@@ -117,7 +117,7 @@ pub const DEFAULT_MIN_FINAL_CLTV_EXPIRY: u64 = 18;
 fn __system_time_size_check() {
        // Use 2 * sizeof(u64) as expected size since the expected underlying implementation is storing
        // a `Duration` since `SystemTime::UNIX_EPOCH`.
-       unsafe { core::mem::transmute_copy::<SystemTime, [u8; 16]>(&SystemTime::UNIX_EPOCH); }
+       unsafe { let _ = core::mem::transmute_copy::<SystemTime, [u8; 16]>(&SystemTime::UNIX_EPOCH); }
 }