forked from boostorg/regex
Try and improve ICU detection to avoid "DLL Hell".
This commit is contained in:
@ -13,6 +13,7 @@
|
||||
#include <unicode/utypes.h>
|
||||
#include <unicode/uchar.h>
|
||||
#include <unicode/coll.h>
|
||||
#include <boost/scoped_ptr.hpp>
|
||||
|
||||
#if defined(_MSC_VER) && !defined(_DLL)
|
||||
#error "Mixing ICU with a static runtime doesn't work"
|
||||
@ -22,5 +23,8 @@ int main()
|
||||
{
|
||||
UErrorCode err = U_ZERO_ERROR;
|
||||
UChar32 c = ::u_charFromName(U_UNICODE_CHAR_NAME, "GREEK SMALL LETTER ALPHA", &err);
|
||||
if(err) return err;
|
||||
U_NAMESPACE_QUALIFIER Locale l;
|
||||
boost::scoped_ptr<U_NAMESPACE_QUALIFIER Collator> p_col(U_NAMESPACE_QUALIFIER Collator::createInstance(l, err));
|
||||
return err;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user