aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/replxx/src/conversion.hxx
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2019-09-03 17:45:58 +0100
committerVsevolod Stakhov <vsevolod@highsecure.ru>2019-09-03 17:45:58 +0100
commit669cd52f685282289590200daed3fc89466e7206 (patch)
tree792c26273dd54dab61b5e94693e1895ff9c5440c /contrib/replxx/src/conversion.hxx
parent8a240656d8378ac20e4c4c3ae61d1a9c33488a20 (diff)
downloadrspamd-669cd52f685282289590200daed3fc89466e7206.tar.gz
rspamd-669cd52f685282289590200daed3fc89466e7206.zip
[Rework] Replace linenoise with replxx
Source: https://github.com/AmokHuginnsson/replxx
Diffstat (limited to 'contrib/replxx/src/conversion.hxx')
-rw-r--r--contrib/replxx/src/conversion.hxx20
1 files changed, 20 insertions, 0 deletions
diff --git a/contrib/replxx/src/conversion.hxx b/contrib/replxx/src/conversion.hxx
new file mode 100644
index 000000000..45d251a6c
--- /dev/null
+++ b/contrib/replxx/src/conversion.hxx
@@ -0,0 +1,20 @@
+#ifndef REPLXX_CONVERSION_HXX_INCLUDED
+#define REPLXX_CONVERSION_HXX_INCLUDED 1
+
+#include "ConvertUTF.h"
+
+namespace replxx {
+
+typedef unsigned char char8_t;
+
+ConversionResult copyString8to32( char32_t* dst, int dstSize, int& dstCount, char const* src );
+ConversionResult copyString8to32( char32_t* dst, int dstSize, int& dstCount, char8_t const* src );
+void copyString32to8( char* dst, int dstSize, char32_t const* src, int srcSize, int* dstCount = nullptr );
+
+namespace locale {
+extern bool is8BitEncoding;
+}
+
+}
+
+#endif