aboutsummaryrefslogtreecommitdiff
path: root/include/ios
diff options
context:
space:
mode:
authorDavid Chisnall <theraven@FreeBSD.org>2012-03-13 14:09:15 +0000
committerDavid Chisnall <theraven@FreeBSD.org>2012-03-13 14:09:15 +0000
commit362d815b81e2b4b66c33b99203d821b8928607e1 (patch)
tree491848d33dbdf1751fd52f321d3fbf70a8e616f2 /include/ios
parent1828c5696f7bf5850943ea6c660a493a5e648669 (diff)
downloadsrc-362d815b81e2b4b66c33b99203d821b8928607e1.tar.gz
src-362d815b81e2b4b66c33b99203d821b8928607e1.zip
Import new version of libc++ into vendor branch.vendor/libc++/r152501
Approved by: dim (mentor)
Notes
Notes: svn path=/vendor/libc++/dist/; revision=232924 svn path=/vendor/libc++/r152501/; revision=232925; tag=vendor/libc++/r152501
Diffstat (limited to 'include/ios')
-rw-r--r--include/ios15
1 files changed, 7 insertions, 8 deletions
diff --git a/include/ios b/include/ios
index 7ea63a31ca71..51d50870b607 100644
--- a/include/ios
+++ b/include/ios
@@ -373,21 +373,19 @@ private:
};
//enum class io_errc
-struct _LIBCPP_VISIBLE io_errc
+_LIBCPP_DECLARE_STRONG_ENUM(io_errc)
{
-enum _ {
stream = 1
};
- _ __v_;
-
- _LIBCPP_ALWAYS_INLINE io_errc(_ __v) : __v_(__v) {}
- _LIBCPP_ALWAYS_INLINE operator int() const {return __v_;}
-};
+_LIBCPP_DECLARE_STRONG_ENUM_EPILOG(io_errc)
template <>
struct _LIBCPP_VISIBLE is_error_code_enum<io_errc> : public true_type { };
+
+#ifdef _LIBCPP_HAS_NO_STRONG_ENUMS
template <>
struct _LIBCPP_VISIBLE is_error_code_enum<io_errc::_> : public true_type { };
+#endif
_LIBCPP_VISIBLE
const error_category& iostream_category();
@@ -574,7 +572,8 @@ public:
typedef typename traits_type::pos_type pos_type;
typedef typename traits_type::off_type off_type;
- _LIBCPP_ALWAYS_INLINE // explicit
+ _LIBCPP_ALWAYS_INLINE
+ _LIBCPP_EXPLICIT
operator bool() const {return !fail();}
_LIBCPP_ALWAYS_INLINE bool operator!() const {return fail();}
_LIBCPP_ALWAYS_INLINE iostate rdstate() const {return ios_base::rdstate();}