Skip to content

Commit c4d73dc

Browse files
committed
Merge branch 'master' into HarmonyPlatform
2 parents 8386973 + c9d0d75 commit c4d73dc

File tree

2 files changed

+16
-7
lines changed

2 files changed

+16
-7
lines changed

INSTALL.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020

2121
* C++17 compliant compiler i.e. g++ 7.3 or later, Clang 6.0 or later, Visual Studio S2017 or later.
2222
* [Vulkan](https://vulkan.lunarg.com/) 1.1 or later. You can use Vulkan (libs and headers) installed from repositories or VulkanSDK.
23-
* [CMake](https://www.cmake.org) 3.7 or later.
23+
* [CMake](https://www.cmake.org) 3.10 or later.
2424

2525
---
2626

@@ -180,7 +180,7 @@ This will also tell CMake that your minimum C++ standard is 17.
180180

181181
For example, a bare minimum CMakeLists.txt file to compile a single file application would be:
182182

183-
cmake_minimum_required(VERSION 3.7)
183+
cmake_minimum_required(VERSION 3.10)
184184
find_package(vsg REQUIRED)
185185
add_executable(myapp "myapp.cpp")
186186
target_link_libraries(myapp vsg::vsg)
@@ -191,7 +191,7 @@ The build system provides macros that create specific cmake targets to use in yo
191191

192192
For example, a bare minimum CMakeLists.txt file adding the mentioned cmake targets would be:
193193

194-
cmake_minimum_required(VERSION 3.7)
194+
cmake_minimum_required(VERSION 3.10)
195195
find_package(vsg REQUIRED)
196196

197197
vsg_setup_dir_vars()

include/vsg/io/convert_utf.h

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,10 +28,19 @@ namespace vsg
2828
inline void convert_utf(const std::string& src, std::string& dst) { dst = src; }
2929
inline void convert_utf(const std::wstring& src, std::wstring& dst) { dst = src; }
3030

31-
#if defined(__cpp_char8_t)
31+
#if defined(__cpp_char8_t)
3232
inline void convert_utf(const std::u8string& src, std::u8string& dst) { dst = src; }
33-
inline void convert_utf(const std::wstring& src, std::u8string& dst) { std::string temp_dst; convert_utf(src, temp_dst); dst.assign(temp_dst.begin(), temp_dst.end()); }
34-
inline void convert_utf(const std::u8string& src, std::wstring& dst) { std::string temp_src(src.begin(), src.end()); convert_utf(temp_src, dst); }
33+
inline void convert_utf(const std::wstring& src, std::u8string& dst)
34+
{
35+
std::string temp_dst;
36+
convert_utf(src, temp_dst);
37+
dst.assign(temp_dst.begin(), temp_dst.end());
38+
}
39+
inline void convert_utf(const std::u8string& src, std::wstring& dst)
40+
{
41+
std::string temp_src(src.begin(), src.end());
42+
convert_utf(temp_src, dst);
43+
}
3544

3645
inline void convert_utf(const char8_t c, std::u8string& dst)
3746
{
@@ -56,7 +65,7 @@ namespace vsg
5665
convert_utf(src, dst);
5766
return dst;
5867
}
59-
#endif
68+
#endif
6069

6170
inline void convert_utf(const char c, std::string& dst)
6271
{

0 commit comments

Comments
 (0)