Currently we only enable the use of is_final(...) with Clang. GCC also provides is_final(...) since 4.7 in all standard modes. This patch creates the macro _LIBCPP_HAS_IS_FINAL to note the availability of __is_final.
Details
Details
Diff Detail
Diff Detail
Event Timeline
Comment Actions
Change all occurrences of __is_final(Tp) to use is_final<Tp>::value.
Perhaps we should use _LIBCPP_HAS_NO_IS_FINAL instead of _LIBCPP_HAS_IS_FINAL?
Comment Actions
Only expose is_tuple in C++14 and beyond. Create and internally use __libcpp_is_final in all other standard modes.
Comment Actions
What do you think of making __libcpp_is_final be false when we don't have __is_final.
Then the #if in unordered_map, memory, map, etc. can be removed.
Comment Actions
Address @mclow.list's review comments. Default __libcpp_is_final to false when we don't have the intrinsics and remove the preprocessor blocks around its usage.