aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/include/winapi/handle.hpp
diff options
context:
space:
mode:
authorEgor Tensin <egor@tensin.name>2026-06-12 17:49:43 +0200
committerEgor Tensin <egor@tensin.name>2026-06-12 22:39:06 +0200
commit6a335fcca28693aa9039ad4e8a13ff71e9d2f9cd (patch)
treeda2c0a81932306c52d192425743e5c9efe4ae88a /include/winapi/handle.hpp
parentminor fixes (diff)
downloadwinapi-common-6a335fcca28693aa9039ad4e8a13ff71e9d2f9cd.tar.gz
winapi-common-6a335fcca28693aa9039ad4e8a13ff71e9d2f9cd.zip
unify my .clang-format files
Diffstat (limited to 'include/winapi/handle.hpp')
-rw-r--r--include/winapi/handle.hpp17
1 files changed, 13 insertions, 4 deletions
diff --git a/include/winapi/handle.hpp b/include/winapi/handle.hpp
index 23e5a3c..c0f85f4 100644
--- a/include/winapi/handle.hpp
+++ b/include/winapi/handle.hpp
@@ -27,10 +27,17 @@ public:
Handle() = default;
explicit Handle(HANDLE);
- HANDLE get() const { return m_impl.get(); }
- HANDLE ptr() const { return get(); }
+ HANDLE get() const {
+ return m_impl.get();
+ }
- explicit operator HANDLE() const { return ptr(); }
+ HANDLE ptr() const {
+ return get();
+ }
+
+ explicit operator HANDLE() const {
+ return ptr();
+ }
bool is_valid() const;
static bool is_valid(HANDLE);
@@ -89,7 +96,9 @@ public:
}
void inherit(bool yes = true) const;
- void dont_inherit() const { inherit(false); }
+ void dont_inherit() const {
+ inherit(false);
+ }
private:
struct Close {