summaryrefslogtreecommitdiff
path: root/src/utils/string.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/utils/string.cpp')
-rw-r--r--src/utils/string.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/utils/string.cpp b/src/utils/string.cpp
index 04d5f031..0785429d 100644
--- a/src/utils/string.cpp
+++ b/src/utils/string.cpp
@@ -18,14 +18,14 @@
* 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*
*/
-#include <string>
-#include <cctype>
+
#include "utils/string.hpp"
+#include <cctype>
+#include <algorithm>
+
std::string utils::toupper(std::string s)
{
- for (int j=0; j<s.length(); ++j)
- s[j]=std::toupper(s[j]);
+ std::transform(s.begin(), s.end(), s.begin(), (int(*)(int)) toupper);
return s;
-}
-
+}