Crate likely_polyfill

Crate likely_polyfill 

Source
Expand description

As a workaround to their stabilization in the standard library remaining perma-open, this crate provides the cold_path, likely, and unlikely hints built on the #[cold] annotation as copied and pasted from the standard library source.

Functionsยง

cold_path
Hints to the compiler that current code path is cold.
likely
Hints to the compiler that branch condition is likely to be true. Returns the value passed to it.
unlikely
Hints to the compiler that branch condition is likely to be false. Returns the value passed to it.