Hacker News new | ask | show | jobs
by the_gipsy 616 days ago
There is no error here, just a closed channel (e.g. finished successfully is indistinguishable).

You do need to use either two channels (horrible code) or some kind of Result{T,error} wrapper (bad language design).