Hacker News new | ask | show | jobs
by zimpenfish 110 days ago
> The real hack to me is that anything which simply has Lock() and Unlock() methods is considered uncopyable.

It's a shame they made them generic, taking no arguments and returning nothing; if they'd gone for `Lock(sync.LockType)` or something like that, it would be more difficult to accidentally trigger the `noCopy` flag.