File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -67,6 +67,8 @@ namespace cppjson
6767 Object& operator =(Object&&) = default ;
6868 ~Object () = default ;
6969
70+ [[nodiscard]] bool IsEmpty () const noexcept { return this ->_nodes .empty (); }
71+
7072 class ObjectProxy
7173 {
7274 public:
@@ -76,14 +78,14 @@ namespace cppjson
7678 requires (!std::same_as<std::remove_cvref_t <T>, JsonObject>)
7779 explicit (false ) operator T&()
7880 {
79- return this ->_object .get ().As <T >();
81+ return this ->_object .get ().As <std:: remove_cvref_t <T> >();
8082 }
8183
8284 template <typename T>
8385 requires (!std::same_as<std::remove_cvref_t <T>, JsonObject>)
8486 explicit (false ) operator const T&() const
8587 {
86- return this ->_object .get ().As <T >();
88+ return this ->_object .get ().As <const std:: remove_cvref_t <T> >();
8789 }
8890
8991 template <typename T>
You can’t perform that action at this time.
0 commit comments