Use a const block

Co-authored-by: Alan Wu <XrXr@users.noreply.github.com>
This commit is contained in:
Takashi Kokubun 2025-07-16 09:16:55 -07:00
parent 8668e4dd07
commit af1ad78bff

View file

@ -1164,7 +1164,7 @@ fn aligned_stack_bytes(num_slots: usize) -> usize {
num_slots
};
const _: () = assert!(SIZEOF_VALUE == 8, "aligned_stack_bytes() assumes SIZEOF_VALUE == 8");
const { assert!(SIZEOF_VALUE == 8, "aligned_stack_bytes() assumes SIZEOF_VALUE == 8"); }
num_slots * SIZEOF_VALUE
}