@@ -343,10 +343,8 @@ bool operator!=(const Vector<T, Rows> &lhs, const Vector<T, Rows> &rhs)
}
#ifndef __DOXYGEN__
-bool vectorValidateYaml(const ValueNode &obj, unsigned int size);
-#endif /* __DOXYGEN__ */
+bool vectorValidateValueNode(const ValueNode &obj, unsigned int size);
-#ifndef __DOXYGEN__
template<typename T, unsigned int Rows>
std::ostream &operator<<(std::ostream &out, const Vector<T, Rows> &v)
{
@@ -364,7 +362,7 @@ template<typename T, unsigned int Rows>
struct ValueNode::Accessor<Vector<T, Rows>> {
std::optional<Vector<T, Rows>> get(const ValueNode &obj) const
{
- if (!vectorValidateYaml(obj, Rows))
+ if (!vectorValidateValueNode(obj, Rows))
return std::nullopt;
Vector<T, Rows> vector;
@@ -351,7 +351,7 @@ LOG_DEFINE_CATEGORY(Vector)
*/
#ifndef __DOXYGEN__
-bool vectorValidateYaml(const ValueNode &obj, unsigned int size)
+bool vectorValidateValueNode(const ValueNode &obj, unsigned int size)
{
if (!obj.isList())
return false;
The vectorValidateYaml() function predates the refactoring of YamlObject and its rename to ValueNode. It now operates on a ValudeNode, disconnected from the YAML parser. Rename it to vectorValidateValueNode() accordingly. While at it, fold consecutive __DOXYGEN__ conditional blocks into a single one. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> --- include/libcamera/internal/vector.h | 6 ++---- src/libcamera/vector.cpp | 2 +- 2 files changed, 3 insertions(+), 5 deletions(-)