From d4cb6b1419e0cbebbba7270c094cf5f6cfb238a5 Mon Sep 17 00:00:00 2001 From: Jonas Jensen Date: Mon, 18 Mar 2019 10:23:10 +0100 Subject: [PATCH] Correct return type on Batch::indices Current Clang versions and GCC < 8 have ignored that the return type was wrong on this function, probably because of overeager SFINAE implementations, but it's a hard error on GCC 8. This commit fixes compilation on Ubuntu 18.10. --- src/types/Batch.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/types/Batch.hpp b/src/types/Batch.hpp index 17293a4..595015d 100644 --- a/src/types/Batch.hpp +++ b/src/types/Batch.hpp @@ -132,7 +132,7 @@ class Batch { * @param index_ Index of the sample from the batch. * @return Sample number. */ - std::vector indices(size_t index_) { + size_t indices(size_t index_) { return sample_indices[index_]; }