The C++11 std::this_thread is a namespace in the <thread> header that contains functions for querying the current thread id and yielding the current thread execution.
Note that the actual behaviour of yield, sleep_for and sleep_until very much depends on the thread library and OS scheduler.
Compiler Explorer link: https://compiler-explorer.com/z/hzcb6eKde