Skip to content

Commit

Permalink
Add Variant Visitor and more code review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
SergeyRyabinin committed Feb 28, 2024
1 parent 72dcccd commit 68e36fd
Show file tree
Hide file tree
Showing 3 changed files with 232 additions and 186 deletions.
10 changes: 10 additions & 0 deletions include/aws/crt/Utility.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,5 +17,15 @@ namespace Aws
};
static constexpr InPlaceT InPlace{};

template <typename T> struct InPlaceTypeT
{
explicit InPlaceTypeT() = default;
};
/** Variable templates are only available since C++14
* Use a dummy object "Aws::Crt::InPlaceTypeT<T>() in-place instead in C++11"*/
#if defined(__cplusplus) && __cplusplus > 201103L //
template <class T> static constexpr InPlaceTypeT<T> InPlaceType{};
#endif

} // namespace Crt
} // namespace Aws
Loading

0 comments on commit 68e36fd

Please sign in to comment.