cpp-common/bt2: remove useless `_ThisXyz` type aliases
[babeltrace.git] / src / cpp-common / bt2 / integer-range.hpp
index 1dff95aa77a15e403b28654561901e04d198dd38..aafc22e55a8012bf6975d96cded9924e987a15af 100644 (file)
@@ -7,14 +7,14 @@
 #ifndef BABELTRACE_CPP_COMMON_BT2_INTEGER_RANGE_HPP
 #define BABELTRACE_CPP_COMMON_BT2_INTEGER_RANGE_HPP
 
-#include <type_traits>
 #include <cstdint>
+#include <type_traits>
+
 #include <babeltrace2/babeltrace.h>
 
-#include "internal/borrowed-obj.hpp"
+#include "borrowed-object.hpp"
 
 namespace bt2 {
-
 namespace internal {
 
 template <typename ValueT>
@@ -65,12 +65,11 @@ struct ConstIntegerRangeSpec<const bt_integer_range_signed> final
 } /* namespace internal */
 
 template <typename LibObjT>
-class ConstIntegerRange final : public internal::BorrowedObj<LibObjT>
+class ConstIntegerRange final : public BorrowedObject<LibObjT>
 {
 private:
-    using typename internal::BorrowedObj<LibObjT>::_ThisBorrowedObj;
-    using typename internal::BorrowedObj<LibObjT>::_LibObjPtr;
-    using _ThisConstIntegerRange = ConstIntegerRange<LibObjT>;
+    using typename BorrowedObject<LibObjT>::_ThisBorrowedObject;
+    using typename BorrowedObject<LibObjT>::_LibObjPtr;
 
 public:
     using Value =
@@ -78,39 +77,40 @@ public:
                                   std::uint64_t, std::int64_t>::type;
 
 public:
-    explicit ConstIntegerRange(const _LibObjPtr libObjPtr) noexcept : _ThisBorrowedObj {libObjPtr}
+    explicit ConstIntegerRange(const _LibObjPtr libObjPtr) noexcept :
+        _ThisBorrowedObject {libObjPtr}
     {
     }
 
-    ConstIntegerRange(const _ThisConstIntegerRange& range) noexcept : _ThisBorrowedObj {range}
+    ConstIntegerRange(const ConstIntegerRange& range) noexcept : _ThisBorrowedObject {range}
     {
     }
 
-    _ThisConstIntegerRange& operator=(const _ThisConstIntegerRange& range) noexcept
+    ConstIntegerRange& operator=(const ConstIntegerRange& range) noexcept
     {
-        _ThisBorrowedObj::operator=(range);
+        _ThisBorrowedObject::operator=(range);
         return *this;
     }
 
-    bool operator==(const _ThisConstIntegerRange& other) const noexcept
+    bool operator==(const ConstIntegerRange& other) const noexcept
     {
-        return internal::ConstIntegerRangeSpec<LibObjT>::isEqual(this->_libObjPtr(),
-                                                                 other._libObjPtr());
+        return internal::ConstIntegerRangeSpec<LibObjT>::isEqual(this->libObjPtr(),
+                                                                 other.libObjPtr());
     }
 
-    bool operator!=(const _ThisConstIntegerRange& other) const noexcept
+    bool operator!=(const ConstIntegerRange& other) const noexcept
     {
         return !(*this == other);
     }
 
     Value lower() const noexcept
     {
-        return internal::ConstIntegerRangeSpec<LibObjT>::lower(this->_libObjPtr());
+        return internal::ConstIntegerRangeSpec<LibObjT>::lower(this->libObjPtr());
     }
 
     Value upper() const noexcept
     {
-        return internal::ConstIntegerRangeSpec<LibObjT>::upper(this->_libObjPtr());
+        return internal::ConstIntegerRangeSpec<LibObjT>::upper(this->libObjPtr());
     }
 };
 
This page took 0.025977 seconds and 4 git commands to generate.