From 3a5ee90bb5499d8434c9fdc6437aedc23992748c Mon Sep 17 00:00:00 2001 From: Michael Carlberg Date: Wed, 19 Oct 2016 10:10:28 +0200 Subject: [PATCH] fix(string_util): Type error --- include/utils/string.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/utils/string.hpp b/include/utils/string.hpp index 28de72c5..49409b95 100644 --- a/include/utils/string.hpp +++ b/include/utils/string.hpp @@ -56,7 +56,7 @@ namespace string_util { */ inline auto replace_all(const string& haystack, string needle, string replacement) { string replaced; - for (int i = 0; i < haystack.length(); i++) { + for (size_t i = 0; i < haystack.length(); i++) { if (haystack.compare(i, needle.length(), needle) == 0) { replaced += replacement; i += needle.length()-1;