Skip to content

Conversation

@tidely
Copy link

@tidely tidely commented Oct 29, 2025

Calls to std::thread::current() are extremely cheap and already use caching internally. Thread::id() accesses a struct field. This makes it unnecessary to wrap inside of a std::thread_local!.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant