From eabc867c2aa0678cb16e7fee1c44badc489f4928 Mon Sep 17 00:00:00 2001 From: Patrick Pelissier Date: Sun, 10 Jan 2021 08:48:46 +0100 Subject: [PATCH] Rename used namespace for C++ to m_lib --- m-string.h | 8 ++++---- m-tuple.h | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/m-string.h b/m-string.h index 074ad311..e65c6950 100644 --- a/m-string.h +++ b/m-string.h @@ -1731,7 +1731,7 @@ string_utf8_p(string_t str) ((const string_t){{.u.heap = { .size = sizeof(s)-1, .alloc = sizeof(s) } , \ .ptr = ((struct { long long _n; char _d[sizeof (s)]; }){ 0, s })._d }}) #else -namespace m_string { +namespace m_lib { template struct m_aligned_string { string_t string; @@ -1750,7 +1750,7 @@ namespace m_string { } /* Initialize a constant string with the given C string (C++ mode) */ #define STRING_CTE(s) \ - m_string::m_aligned_string(s).string + m_lib::m_aligned_string(s).string #endif /* Initialize and set a string to the given formatted value. */ @@ -2296,7 +2296,7 @@ namespace m_string { #define BOUNDED_STRING_CTE(name, string) \ ((const struct M_C(name, _s) *)((M_C(name, _array_t)){string})) #else -namespace m_string { +namespace m_lib { template struct m_bounded_string { char s[N]; @@ -2308,7 +2308,7 @@ namespace m_string { }; } #define BOUNDED_STRING_CTE(name, string) \ - ((const struct M_C(name, _s) *)(m_string::m_bounded_string(string).s)) + ((const struct M_C(name, _s) *)(m_lib::m_bounded_string(string).s)) #endif diff --git a/m-tuple.h b/m-tuple.h index 29539a04..d1730c74 100644 --- a/m-tuple.h +++ b/m-tuple.h @@ -66,7 +66,7 @@ ( (const int[]) {M_MAP2_C(TUPLEI_ORDER_CONVERT, name, __VA_ARGS__), 0}) #else #include -namespace m_tuple { +namespace m_lib { template struct m_int_array { int data[N]; @@ -79,7 +79,7 @@ namespace m_tuple { }; } #define TUPLE_ORDER(name, ...) \ - (m_tuple::m_int_array({M_MAP2_C(TUPLEI_ORDER_CONVERT, name, __VA_ARGS__), 0}).data) + (m_lib::m_int_array({M_MAP2_C(TUPLEI_ORDER_CONVERT, name, __VA_ARGS__), 0}).data) #endif