From a7ce4ee846cb9b51474d3b44e58fbfa72cd60631 Mon Sep 17 00:00:00 2001 From: Kevin Backhouse Date: Sat, 19 Feb 2022 13:38:46 +0000 Subject: [PATCH] Move Metadatum::toUint32() implementation out of header file. --- include/exiv2/metadatum.hpp | 4 +--- src/metadatum.cpp | 4 ++++ 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/include/exiv2/metadatum.hpp b/include/exiv2/metadatum.hpp index 37c3a8e0..53efd85a 100644 --- a/include/exiv2/metadatum.hpp +++ b/include/exiv2/metadatum.hpp @@ -226,9 +226,7 @@ namespace Exiv2 { /*! @brief Return the n-th component of the value converted to uint32_t. */ - uint32_t toUint32(long n =0) const { - return static_cast(toInt64(n)); - } + uint32_t toUint32(long n =0) const; /*! @brief Return the n-th component of the value converted to float. The return value is -1 if the value is not set and the behaviour diff --git a/src/metadatum.cpp b/src/metadatum.cpp index 9b6f57e6..2a5be1ff 100644 --- a/src/metadatum.cpp +++ b/src/metadatum.cpp @@ -42,6 +42,10 @@ namespace Exiv2 { return os.str(); } + uint32_t Metadatum::toUint32(long n) const { + return static_cast(toInt64(n)); + } + bool cmpMetadataByTag(const Metadatum& lhs, const Metadatum& rhs) { return lhs.tag() < rhs.tag();