Skip to main content

Module hint

Module hint 

Source
Expand description

Compiler and execution hints.

hint โ—‰

Extends: std::{hint}


Functionsยง

assert_uncheckedโš 
๐Ÿ’ฏ core Makes a soundness promise to the compiler that the condition holds.
black_box
โŒ— core Hints the compiler to be maximally pessimistic about what black_box could do.
cold_path
โŒ— core Hints to the compiler that given path is cold, i.e., unlikely to be taken.
likely
โŒ— Indicate that a given condition is likely to be true.
select_unpredictable
โŒ— core Hints the compiler that the condition is branch-unpredictable.
spin_loop
โŒ— core Signals the processor that it is running in a busy-wait spin-loop.
unlikely
โŒ— Indicate that a given condition is likely to be false.
unreachable_uncheckedโš 
๐Ÿ’ฏ core Informs the compiler that the current calling site is not reachable.