diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 81bca99..9fc9ce2 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -18,7 +18,8 @@ PRIVATE yycc/encoding/stl.cpp yycc/encoding/windows.cpp yycc/encoding/iconv.cpp - #yycc/encoding/pycodec.cpp + + yycc/carton/pycodec.cpp ) target_sources(YYCCommonplace PUBLIC @@ -56,7 +57,8 @@ FILES yycc/encoding/stl.hpp yycc/encoding/windows.hpp yycc/encoding/iconv.hpp - yycc/encoding/pycodec.hpp + + yycc/carton/pycodec.hpp ) # Setup header infomations target_include_directories(YYCCommonplace diff --git a/src/yycc/binstore/kernel.hpp b/src/yycc/carton/binstore/kernel.hpp similarity index 100% rename from src/yycc/binstore/kernel.hpp rename to src/yycc/carton/binstore/kernel.hpp diff --git a/src/yycc/clap/kernel.hpp b/src/yycc/carton/clap/kernel.hpp similarity index 100% rename from src/yycc/clap/kernel.hpp rename to src/yycc/carton/clap/kernel.hpp diff --git a/src/yycc/encoding/pycodec.cpp b/src/yycc/carton/pycodec.cpp similarity index 99% rename from src/yycc/encoding/pycodec.cpp rename to src/yycc/carton/pycodec.cpp index 59d6564..f79b072 100644 --- a/src/yycc/encoding/pycodec.cpp +++ b/src/yycc/carton/pycodec.cpp @@ -6,7 +6,7 @@ using namespace std::literals::string_view_literals; namespace op = ::yycc::string::op; -namespace yycc::encoding::pycodec { +namespace yycc::carton::pycodec { #pragma region Encoding Name diff --git a/src/yycc/encoding/pycodec.hpp b/src/yycc/carton/pycodec.hpp similarity index 97% rename from src/yycc/encoding/pycodec.hpp rename to src/yycc/carton/pycodec.hpp index 5251fba..7816220 100644 --- a/src/yycc/encoding/pycodec.hpp +++ b/src/yycc/carton/pycodec.hpp @@ -9,12 +9,12 @@ // Choose the backend of PyCodec module #if defined(YYCC_FEAT_ICONV) // We try Iconv first in any cases. -#include "iconv.hpp" +#include "../encoding/iconv.hpp" #define YYCC_PYCODEC_ICONV_BACKEND #define YYCC_PYCODEC_BACKEND_NS ::yycc::encoding::iconv #elif defined(YYCC_OS_WINDOWS) && defined(YYCC_STL_MSSTL) // If we can not use Iconv, we try to fallback to Windows implementation. -#include "windows.hpp" +#include "../encoding/windows.hpp" #define YYCC_PYCODEC_WIN32_BACKEND #define YYCC_PYCODEC_BACKEND_NS ::yycc::encoding::windows #else @@ -22,7 +22,7 @@ #error "Can not find viable encoding convertion solution in current environment for PyCodec module." #endif -namespace yycc::encoding::pycodec { +namespace yycc::carton::pycodec { /// @brief The universal name of encoding. using EncodingName = std::u8string_view; diff --git a/testbench/CMakeLists.txt b/testbench/CMakeLists.txt index 3665c08..8ba0e64 100644 --- a/testbench/CMakeLists.txt +++ b/testbench/CMakeLists.txt @@ -21,6 +21,8 @@ PRIVATE yycc/encoding/stl.cpp yycc/encoding/windows.cpp yycc/encoding/iconv.cpp + + yycc/carton/pycodec.cpp ) target_sources(YYCCTestbench PRIVATE diff --git a/testbench/yycc/carton/pycodec.cpp b/testbench/yycc/carton/pycodec.cpp new file mode 100644 index 0000000..cc1dc4d --- /dev/null +++ b/testbench/yycc/carton/pycodec.cpp @@ -0,0 +1,10 @@ +#include +#include +#include +#include "../../shared/literals.hpp" + +#define ENC ::yycc::carton::pycodec + +namespace yycctest::carton::pycodec { + +} \ No newline at end of file