aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2014-07-14 15:58:12 +0200
committerMax Kellermann <max@duempel.org>2014-07-14 15:58:12 +0200
commit393cb7fd7de87c535e4c90af0a024d75842582f9 (patch)
treef9ae875415bc4d7b73af9d1b2f5e877725c67475 /src
parente74e1256d459894d81f0ad1e4a9c7a2b89f19078 (diff)
downloadmpd-393cb7fd7de87c535e4c90af0a024d75842582f9.tar.gz
mpd-393cb7fd7de87c535e4c90af0a024d75842582f9.tar.xz
mpd-393cb7fd7de87c535e4c90af0a024d75842582f9.zip
util/Cast: suppress "unused function" warning by using "inline"
Diffstat (limited to 'src')
-rw-r--r--src/util/Cast.hxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/util/Cast.hxx b/src/util/Cast.hxx
index 8fd1fe5e0..ca4b62832 100644
--- a/src/util/Cast.hxx
+++ b/src/util/Cast.hxx
@@ -35,14 +35,14 @@
/**
* Offset the given pointer by the specified number of bytes.
*/
-static constexpr void *
+static inline constexpr void *
OffsetPointer(void *p, ptrdiff_t offset)
{
return (char *)p + offset;
}
template<typename T, typename U>
-static constexpr T *
+static inline constexpr T *
OffsetCast(U *p, ptrdiff_t offset)
{
return reinterpret_cast<T *>(OffsetPointer(p, offset));