[icinga-checkins] icinga.org: icinga2/master: Add missing default arguments

git at icinga.org git at icinga.org
Tue Nov 11 23:49:34 CET 2014


Module: icinga2
Branch: master
Commit: 2d7ce624389d4111b27dc6f2dc7a9b4ba2bf97a4
URL:    https://git.icinga.org/?p=icinga2.git;a=commit;h=2d7ce624389d4111b27dc6f2dc7a9b4ba2bf97a4

Author: Gunnar Beutner <gunnar.beutner at netways.de>
Date:   Tue Nov 11 23:48:17 2014 +0100

Add missing default arguments

refs #7622

---

 lib/base/string.hpp |   14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/lib/base/string.hpp b/lib/base/string.hpp
index c117cef..dd27693 100644
--- a/lib/base/string.hpp
+++ b/lib/base/string.hpp
@@ -161,37 +161,37 @@ public:
 		return m_Data;
 	}
 
-	inline SizeType Find(const String& str, SizeType pos) const
+	inline SizeType Find(const String& str, SizeType pos = 0) const
 	{
 		return m_Data.find(str, pos);
 	}
 
-	inline SizeType RFind(const String& str, SizeType pos) const
+	inline SizeType RFind(const String& str, SizeType pos = NPos) const
 	{
 		return m_Data.rfind(str, pos);
 	}
 
-	inline SizeType FindFirstOf(const char *s, SizeType pos) const
+	inline SizeType FindFirstOf(const char *s, SizeType pos = 0) const
 	{
 		return m_Data.find_first_of(s, pos);
 	}
 
-	inline SizeType FindFirstOf(char ch, SizeType pos) const
+	inline SizeType FindFirstOf(char ch, SizeType pos = 0) const
 	{
 		return m_Data.find_first_of(ch, pos);
 	}
 
-	inline SizeType FindFirstNotOf(const char *s, SizeType pos) const
+	inline SizeType FindFirstNotOf(const char *s, SizeType pos = 0) const
 	{
 		return m_Data.find_first_not_of(s, pos);
 	}
 
-	inline SizeType FindFirstNotOf(char ch, SizeType pos) const
+	inline SizeType FindFirstNotOf(char ch, SizeType pos = 0) const
 	{
 		return m_Data.find_first_not_of(ch, pos);
 	}
 
-	inline String SubStr(SizeType first, SizeType len) const
+	inline String SubStr(SizeType first, SizeType len = NPos) const
 	{
 		return m_Data.substr(first, len);
 	}



More information about the icinga-checkins mailing list