Why atomic::is_lock_free() is not a constexpr and/or static function?

niXman i.nixman@gmail.com
Sun Sep 16 13:03:00 GMT 2012


Hello,

Reading the implementation of the atomics, I have found that the
'is_lock_free()' method is not 'constexpr' nor even 'static', while
this method uses the 'bool __ atomic_is_lock_free()' builtin function,
the result of which is known in compile-time.
And here, in fact, the question is, why
'std::atomic<>::is_lock_free()' is not 'constexpr' and/or 'static'?


-- 
Regards,
niXman
___________________________________________________
Dual-target(32 & 64 bit) MinGW compilers for 32 and 64 bit Windows:
http://sourceforge.net/projects/mingwbuilds/



More information about the Gcc-help mailing list