Have a structure holding a "do we have a thread" flag and a thread handle.
If there were a distinguished value for a pthread_t that means "no
thread", we wouldn't need this, but there isn't, so we do need this.
(It's somewhat like an Optional<thread> in Swift.)
This cleans up some "reference to uninitialized data" warnings on
Windows (not sure why we didn't get the same warnings on UN*X, as you're
still passing an uninitialized pthread_t, although it may not be obvious
to a compiler that, if pthread_create() fails, it won't necessarily
initialize the pointed-to pthread_t), and gets rid of some cases where
we need different function signatures on Windows and UN*X.
It also forces the "does this handle refer to a thread?" flag and the
handle itself to travel together.