diff options
author | Geir Storli <geirst@yahoo-inc.com> | 2017-04-04 19:22:35 +0000 |
---|---|---|
committer | Geir Storli <geirst@yahoo-inc.com> | 2017-04-04 19:24:55 +0000 |
commit | d8b05c79c106204ee76726aff4d3f0cb84d8fc99 (patch) | |
tree | d33b0e6dbc3c2130ab4bcc40453b17b5ef34ce5b /vespalib | |
parent | b3785113f3df9bd64d5cfb7d6fda2cae8144544a (diff) |
Change return type from int -> size_t.
Diffstat (limited to 'vespalib')
-rw-r--r-- | vespalib/src/vespa/vespalib/util/arraysize.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/vespalib/src/vespa/vespalib/util/arraysize.h b/vespalib/src/vespa/vespalib/util/arraysize.h index b34b76a981e..f29a3e6e74d 100644 --- a/vespalib/src/vespa/vespalib/util/arraysize.h +++ b/vespalib/src/vespa/vespalib/util/arraysize.h @@ -4,7 +4,8 @@ namespace vespalib { -template <typename T, int N> int arraysize(const T (&)[N]) { return N; } +template <typename T, size_t N> +constexpr size_t arraysize(const T (&)[N]) { return N; } } // namespace vespalib |