File tree Expand file tree Collapse file tree 1 file changed +8
-6
lines changed
Expand file tree Collapse file tree 1 file changed +8
-6
lines changed Original file line number Diff line number Diff line change @@ -8,14 +8,16 @@ import mcpplibs.primitives.traits.underlying;
88
99export namespace mcpplibs ::primitives {
1010
11- template <underlying_type T,
12- policy::policy_type... Policies>
13- template <underlying_type T,
14- policy::policy_type... Policies>
11+ template <underlying_type T, policy::policy_type... Policies> class primitive {
12+ public:
1513 using value_type = T;
1614 using policies = std::tuple<Policies...>;
17- constexpr explicit primitive (T v) noexcept : value(v) {}
18- T value;
15+ constexpr explicit primitive (T v) noexcept : value_(v) {}
16+ constexpr value_type &value () noexcept { return value_; }
17+ constexpr value_type const &value () const noexcept { return value_; }
18+
19+ private:
20+ T value_;
1921};
2022
2123} // namespace mcpplibs::primitives
You can’t perform that action at this time.
0 commit comments