
26 Mar
2007
26 Mar
'07
6:04 p.m.
Howard Hinnant wrote:
Fair point. Perhaps we should go back to a more fundamental question:
std::thread t(f); ... t.cancel(); // Logically is this a const or non-const operation on the thread executing t/f?
I prefer to first ask "does it matter"? If you can't observe the cancelation state of t and if you are assured that t.cancel is valid no matter what else is going on with t, what difference does a const/non-const label make to the external observer? (Internally there is a flag being set, of course.)