From 28ff72e578df24ee0f77f73cee1048317e659c66 Mon Sep 17 00:00:00 2001 From: Martin Moene Date: Tue, 21 May 2024 14:39:05 +0200 Subject: [PATCH] Change namespace nsrs to ring_span_lite as used in ring_span.hpp Use integral_constant and bool_constant supplied by ring_span.hpp --- include/nonstd/ring.hpp | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/include/nonstd/ring.hpp b/include/nonstd/ring.hpp index df034c0..30305f8 100644 --- a/include/nonstd/ring.hpp +++ b/include/nonstd/ring.hpp @@ -18,18 +18,10 @@ # include #endif -namespace nonstd { - -namespace nsrs { +namespace nonstd { namespace ring_span_lite { namespace std11 { -template< class T, T v > struct integral_constant { enum { value = v }; }; -template< bool B > struct bool_constant : integral_constant{}; - -typedef bool_constant< true > true_type; -typedef bool_constant< false > false_type; - template< class C > typename C::iterator begin( C & c ) { return c.begin(); } @@ -354,11 +346,11 @@ class ring RingSpan rs; }; -} // namespace nsrs +} // namespace ring_span_lite // Make types available in namespace nonstd: -using nsrs::ring; +using ring_span_lite::ring; } // namespace nonstd