Tracking Issue for likely_unlikely and cold_path · Issue #136873 · rust-lang/rust (original) (raw)

Skip to content

Provide feedback

Saved searches

Use saved searches to filter your results more quickly

Sign up

Appearance settings

@tgross35

Description

@tgross35

Feature gate: #![feature(likely_unlikely)], #![feature(cold_path)]

This is a tracking issue for core::hint::{likely, unlikely, cold_path}.

Please also see the meta discussion at #26179.

Public API

// core::hint

// Usable via #![feature(cold_path)] pub const fn cold_path();

// Usable via #![feature(likely_unlikely)] pub const fn likely(b: bool) -> bool; pub const fn unlikely(b: bool) -> bool;

Steps / History

Unresolved Questions

  1. https://std-dev-guide.rust-lang.org/feature-lifecycle/stabilization.html