Comment

Comment by steveklabnik

If you really need something that's only for a single thread, then using TLS is gonna be better than a static.

(I actually want to write a blog post about this... haven't done so yet though. People reach for static too often and thread_local! too little, IMHO. Of course, not needing either is best.)

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton