All,
New user here. Just downloaded and tried to compile on Microsoft Visual
Studio 2013 and apparently MS has added the "strtoll" and "strtoull"
functions (finally standards compliant?). This unfortunately conflicts with
code in soci-platform.h, giving the infamous error "C2883" that I saw from
a previous poster.
The current workaround I'm using is to change the code to add another "#if"
to check for later versions of VS, as such:
--------------------------------------------------------------
...
// Define if you have the strtoll and strtoull variants.
#if _MSC_VER >= 1300
# define HAVE_STRTOLL 1
# define HAVE_STRTOULL 1
#if _MSC_VER < 1800
namespace std {
inline long long strtoll(char const* str, char** str_end, int base)
{
return _strtoi64(str, str_end, base);
}
inline unsigned long long strtoull(char const* str, char** str_end, int
base)
{
return _strtoui64(str, str_end, base);
}
}
#endif
#else
# undef HAVE_STRTOLL
# undef HAVE_STRTOULL
# error "Visual C++ versions prior 1300 don't support _strtoi64 and
_strtoui64"
#endif // _MSC_VER >= 1300
#endif // _MSC_VER
...
--------------------------------------------------
This is a "brute force" workaround -- a quick google search tells me that
this was added into VS fairly recently, but I don't know the exact compiler
version it was added into. I just know that this works for me.
Hopefully this will be of use to someone. Not sure if this is the "correct"
way to do the fix though ...
Thanks,
--
John C. Price
Integration Engineer
FD Software Enterprises, LLC
------------------------------------------------------------------------------
Managing the Performance of Cloud-Based Applications
Take advantage of what the Cloud has to offer - Avoid Common Pitfalls.
Read the Whitepaper.
http://pubads.g.doubleclick.net/gampad/clk?id=121051231&iu=/4140/ostg.clktrk
_______________________________________________
soci-users mailing list
soci-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/soci-users