use inline functions instead of macros in charset.h
This commit is contained in:
@@ -25,10 +25,10 @@
|
|||||||
#include <config.h>
|
#include <config.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(SUPPORTED_LOCALES) && defined(HAVE_ICONV_H)
|
|
||||||
|
|
||||||
#include <string>
|
#include <string>
|
||||||
|
|
||||||
|
#if defined(SUPPORTED_LOCALES) && defined(HAVE_ICONV_H)
|
||||||
|
|
||||||
void init_current_locale();
|
void init_current_locale();
|
||||||
|
|
||||||
void utf_to_locale(std::string &);
|
void utf_to_locale(std::string &);
|
||||||
@@ -42,16 +42,16 @@ void str_pool_locale_to_utf(char *&);
|
|||||||
|
|
||||||
#else
|
#else
|
||||||
|
|
||||||
#define init_current_locale();
|
void init_current_locale() { }
|
||||||
|
|
||||||
#define utf_to_locale(x);
|
void utf_to_locale(std::string &) { }
|
||||||
#define locale_to_utf(x);
|
void locale_to_utf(std::string &) { }
|
||||||
|
|
||||||
#define utf_to_locale_cpy(x) (x)
|
std::string &utf_to_locale_cpy(const std::string &s) { return s; }
|
||||||
#define locale_to_utf_cpy(x) (x)
|
std::string &locale_to_utf_cpy(const std::string &s) { return s; }
|
||||||
|
|
||||||
#define str_pool_utf_to_locale(x);
|
void str_pool_utf_to_locale(char *&) { }
|
||||||
#define str_pool_locale_to_utf(x);
|
void str_pool_locale_to_utf(char *&) { }
|
||||||
|
|
||||||
#endif // SUPPORTED_LOCALES && HAVE_ICONV_H
|
#endif // SUPPORTED_LOCALES && HAVE_ICONV_H
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user