[geos-commits] r3562 - trunk/tests/unit/capi
svn_geos at osgeo.org
svn_geos at osgeo.org
Sat Jan 7 16:08:10 EST 2012
Author: mloskot
Date: 2012-01-07 13:08:10 -0800 (Sat, 07 Jan 2012)
New Revision: 3562
Modified:
trunk/tests/unit/capi/GEOSisValidDetailTest.cpp
Log:
Missing <cctype> header for toupper. Fixed Visual C++ warning.
Modified: trunk/tests/unit/capi/GEOSisValidDetailTest.cpp
===================================================================
--- trunk/tests/unit/capi/GEOSisValidDetailTest.cpp 2012-01-06 21:53:35 UTC (rev 3561)
+++ trunk/tests/unit/capi/GEOSisValidDetailTest.cpp 2012-01-07 21:08:10 UTC (rev 3562)
@@ -5,6 +5,7 @@
// geos
#include <geos_c.h>
// std
+#include <cctype>
#include <cstdarg>
#include <cstdio>
#include <cstdlib>
@@ -53,10 +54,13 @@
return ret;
}
- void strToUpper(std::string &str)
+ void strToUpper(std::string &str)
{
- for(size_t i = 0, len = str.size(); i < len; ++i)
- str[i] = std::toupper(str[i]);
+ using std::toupper;
+ using std::string;
+
+ for(string::size_type i = 0, len = str.size(); i < len; ++i)
+ str[i] = static_cast<string::value_type>(toupper(str[i]));
}
~test_capiisvaliddetail_data()
More information about the geos-commits
mailing list