Browse Source

meta: try to make the linter happy

skypjack 4 months ago
parent
commit
3e5842a467
1 changed files with 6 additions and 2 deletions
  1. 6 2
      src/entt/meta/meta.hpp

+ 6 - 2
src/entt/meta/meta.hpp

@@ -214,8 +214,12 @@ class meta_any {
     }
     }
 
 
     [[nodiscard]] const auto &fetch_node() const {
     [[nodiscard]] const auto &fetch_node() const {
-        ENTT_ASSERT(vtable != nullptr, "Invalid vtable function");
-        return (node == nullptr) ? (vtable(internal::meta_traits::is_none, *this, nullptr), *node) : *node;
+        if(node == nullptr) {
+            ENTT_ASSERT(vtable != nullptr, "Invalid vtable function");
+            vtable(internal::meta_traits::is_none, *this, nullptr);
+        }
+
+        return *node;
     }
     }
 
 
 public:
 public: