diff options
author | rtk0c <[email protected]> | 2022-11-27 12:04:31 -0800 |
---|---|---|
committer | rtk0c <[email protected]> | 2022-11-27 12:04:31 -0800 |
commit | 182c8f8357739f905bbd721006480502435b6b43 (patch) | |
tree | 082613a474d863182e2ad8f2167f1643f26e67a3 /app/source/Cplt/Utils/IO/Helper.hpp | |
parent | b01ed99a1cd0c863c8709930658513c04dd70f61 (diff) |
Update brace style to match rest of my projectscplt-imgui
Diffstat (limited to 'app/source/Cplt/Utils/IO/Helper.hpp')
-rw-r--r-- | app/source/Cplt/Utils/IO/Helper.hpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/app/source/Cplt/Utils/IO/Helper.hpp b/app/source/Cplt/Utils/IO/Helper.hpp index 7a84103..b8f4e6f 100644 --- a/app/source/Cplt/Utils/IO/Helper.hpp +++ b/app/source/Cplt/Utils/IO/Helper.hpp @@ -7,8 +7,7 @@ namespace DataStreamAdapters { /// Helper to invoke either Read() or ReadObject(). /// This is intended for writing IO adapters, users that's writing IO logic shouldn't using this - it increases compile time while reducing readability. template <class TAdapter, class T> -void ReadHelper(InputDataStream& stream, T& t) -{ +void ReadHelper(InputDataStream& stream, T& t) { if constexpr (!std::is_same_v<TAdapter, void>) { stream.ReadObjectAdapted<TAdapter>(t); } else if constexpr (requires(T tt, InputDataStream ss) { ss.Read(tt); }) { @@ -25,8 +24,7 @@ void ReadHelper(InputDataStream& stream, T& t) /// Helper to invoke either Write() or WriteObject(). /// This is intended for writing IO adapters, users that's writing IO logic shouldn't using this - it increases compile time while reducing readability. template <class TAdapter, class T> -void WriteHelper(OutputDataStream& stream, T& t) -{ +void WriteHelper(OutputDataStream& stream, T& t) { if constexpr (!std::is_same_v<TAdapter, void>) { stream.WriteObjectAdapted<TAdapter>(t); } else if constexpr (requires(T tt, OutputDataStream ss) { ss.Write(tt); }) { |