Skip to content

Commit

Permalink
Only expose public extern headers
Browse files Browse the repository at this point in the history
  • Loading branch information
muit committed Aug 14, 2024
1 parent 42bab5e commit cd0d0c5
Show file tree
Hide file tree
Showing 16 changed files with 4,913 additions and 4,296 deletions.
3 changes: 2 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,8 @@ generate_export_header(Pipe
pipe_target_define_platform(Pipe)

target_include_directories(Pipe PUBLIC $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/Include>)
file(GLOB_RECURSE PIPE_SOURCE_FILES CONFIGURE_DEPENDS Src/*.cpp Src/*.h)
target_include_directories(Pipe PRIVATE $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/Src>)
file(GLOB_RECURSE PIPE_SOURCE_FILES CONFIGURE_DEPENDS Src/*.cpp Src/*.c)
target_sources(Pipe PRIVATE ${PIPE_SOURCE_FILES})
target_compile_definitions(Pipe PRIVATE NOMINMAX)

Expand Down
10 changes: 5 additions & 5 deletions Include/Pipe/Core/String.h
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
#include "Pipe/Core/STDFormat.h"
#include "Pipe/Core/StringView.h"
#include "Pipe/Core/Utility.h"
#include "Pipe/Extern/utf8.h"
#include "Pipe/Extern/utf8/unchecked.h"
#include "Pipe/Memory/STLAllocator.h"
#include "PipeArrays.h"
#include "PipeSerializeFwd.h"
Expand Down Expand Up @@ -120,19 +120,19 @@ namespace p
}
else if constexpr (sizeof(FromChar) == 1 && sizeof(ToChar) == 2)
{
utf8::utf8to16(source.begin(), source.end(), std::back_inserter(dest));
utf8::unchecked::utf8to16(source.begin(), source.end(), std::back_inserter(dest));
}
else if constexpr (sizeof(FromChar) == 2 && sizeof(ToChar) == 1)
{
utf8::utf16to8(source.begin(), source.end(), std::back_inserter(dest));
utf8::unchecked::utf16to8(source.begin(), source.end(), std::back_inserter(dest));
}
else if constexpr (sizeof(FromChar) == 1 && sizeof(ToChar) == 4)
{
utf8::utf8to32(source.begin(), source.end(), std::back_inserter(dest));
utf8::unchecked::utf8to32(source.begin(), source.end(), std::back_inserter(dest));
}
else if constexpr (sizeof(FromChar) == 4 && sizeof(ToChar) == 1)
{
utf8::utf32to8(source.begin(), source.end(), std::back_inserter(dest));
utf8::unchecked::utf32to8(source.begin(), source.end(), std::back_inserter(dest));
}
else
{
Expand Down
Loading

0 comments on commit cd0d0c5

Please sign in to comment.