diff --git a/include/etl/cstring.h b/include/etl/cstring.h index 1d073417..6812e2a8 100644 --- a/include/etl/cstring.h +++ b/include/etl/cstring.h @@ -251,6 +251,15 @@ namespace etl } }; #endif + + //*************************************************************************** + /// Make string from string literal or char array + //*************************************************************************** + template + etl::string make_string(const char (&text) [MAX_SIZE]) + { + return etl::string(text); + } } #include "private/minmax_pop.h" diff --git a/include/etl/u16string.h b/include/etl/u16string.h index 4ef1d146..f52417eb 100644 --- a/include/etl/u16string.h +++ b/include/etl/u16string.h @@ -251,6 +251,15 @@ namespace etl } }; #endif + + //*************************************************************************** + /// Make u16string from UTF-8 string literal or char16_t array + //*************************************************************************** + template + etl::u16string make_string(const char16_t (&text) [MAX_SIZE]) + { + return etl::u16string(text); + } } #include "private/minmax_pop.h" diff --git a/include/etl/u32string.h b/include/etl/u32string.h index 64112c49..3eec812e 100644 --- a/include/etl/u32string.h +++ b/include/etl/u32string.h @@ -251,6 +251,15 @@ namespace etl } }; #endif + + //*************************************************************************** + /// Make u32string from UTF-16 string literal or char32_t array + //*************************************************************************** + template + etl::u32string make_string(const char32_t (&text) [MAX_SIZE]) + { + return etl::u32string(text); + } } #include "private/minmax_pop.h" diff --git a/include/etl/version.h b/include/etl/version.h index 596fd2bc..3f91e496 100644 --- a/include/etl/version.h +++ b/include/etl/version.h @@ -38,7 +38,7 @@ SOFTWARE. ///\ingroup utilities #define ETL_VERSION_MAJOR 15 -#define ETL_VERSION_MINOR 1 +#define ETL_VERSION_MINOR 2 #define ETL_VERSION_PATCH 0 #define ETL_VERSION ETL_STRINGIFY(ETL_VERSION_MAJOR) "." ETL_STRINGIFY(ETL_VERSION_MINOR) "." ETL_STRINGIFY(ETL_VERSION_PATCH) diff --git a/include/etl/wstring.h b/include/etl/wstring.h index 6eab06a6..9b28eef2 100644 --- a/include/etl/wstring.h +++ b/include/etl/wstring.h @@ -252,6 +252,15 @@ namespace etl } }; #endif + + //*************************************************************************** + /// Make wstring from wide string literal or wchar_t array + //*************************************************************************** + template + etl::wstring make_string(const wchar_t (&text) [MAX_SIZE]) + { + return etl::wstring(text); + } } #include "private/minmax_pop.h" diff --git a/library.json b/library.json index ba576b23..477ce514 100644 --- a/library.json +++ b/library.json @@ -1,6 +1,6 @@ { "name": "Embedded Template Library", - "version": "15.1.0", + "version": "15.2.0", "authors": { "name": "John Wellbelove", "email": "" diff --git a/library.properties b/library.properties index 43611b42..3bb62455 100644 --- a/library.properties +++ b/library.properties @@ -1,5 +1,5 @@ name=Embedded Template Library -version=15.1.0 +version=15.2.0 author= John Wellbelove maintainer=John Wellbelove license=MIT diff --git a/support/Release notes.txt b/support/Release notes.txt index bf5b38b7..fe0d467e 100644 --- a/support/Release notes.txt +++ b/support/Release notes.txt @@ -1,3 +1,8 @@ +=============================================================================== +15.2.0 +Added function adaptors and removed built-in sort functions from indirect_vector. +Added etl::make_string for all string types. + =============================================================================== 15.1.0 Fixes to the conditional compilation of choose_tag_types.h and diff --git a/test/vs2017/etl.vcxproj b/test/vs2017/etl.vcxproj index 81664aaa..0481a010 100644 --- a/test/vs2017/etl.vcxproj +++ b/test/vs2017/etl.vcxproj @@ -941,6 +941,7 @@ + diff --git a/test/vs2017/etl.vcxproj.filters b/test/vs2017/etl.vcxproj.filters index e697a858..47a5caf4 100644 --- a/test/vs2017/etl.vcxproj.filters +++ b/test/vs2017/etl.vcxproj.filters @@ -1256,6 +1256,9 @@ Source Files + + Source Files + diff --git a/todo.txt b/todo.txt index 2fda3c72..bf922e23 100644 --- a/todo.txt +++ b/todo.txt @@ -1,7 +1,7 @@ List of ideas for future development. -delegate_timer (Variant of callback_timer) - delegate_state_chart (Variant of state_chart) Finish secure containers + +Finish move semantics for all containers