[v3] improve exception text when threads not enabled
Joe Buck
Joe.Buck@synopsys.COM
Mon Aug 13 15:47:00 GMT 2012
On Sun, Aug 12, 2012 at 08:02:30PM +0100, Jonathan Wakely wrote:
> This improves the fairly uninformative "Operation not supported"
> message given when std::thread is used without linking to libpthread.
>
> Now you get:
>
> terminate called after throwing an instance of 'std::system_error'
> what(): Enable multithreading to use std::thread: Operation not permitted
> Aborted
The new message still seems deficient. The issue is that the executable
does not contain any thread support; "not permitted" usually suggests a
permission violation (like trying to write a read-only file). Perhaps "no
thread support found" should be used instead of "Operation not permitted".
More information about the Libstdc++
mailing list