Sat, 19 Apr 2025 11:33:15 +0200
fix code not compiling with GCC 15
CHANGELOG | file | annotate | diff | comparison | revisions | |
docs/Writerside/topics/about.md | file | annotate | diff | comparison | revisions | |
src/cx/common.h | file | annotate | diff | comparison | revisions |
--- a/CHANGELOG Thu Apr 17 21:45:01 2025 +0200 +++ b/CHANGELOG Sat Apr 19 11:33:15 2025 +0200 @@ -15,6 +15,7 @@ * fixes implementation of cxBufferTerminate() * fixes allocator arguments for some printf.h functions not being const * fixes that cx_tree_search() did not investigate subtrees with equally good distance + * removes the use of C23 attributes because they don't mix well with GNU attributes in GCC 15 Version 3.1 - 2025-02-11 ------------------------
--- a/docs/Writerside/topics/about.md Thu Apr 17 21:45:01 2025 +0200 +++ b/docs/Writerside/topics/about.md Sat Apr 19 11:33:15 2025 +0200 @@ -42,6 +42,7 @@ * fixes implementation of cxBufferTerminate() * fixes allocator arguments for some printf.h functions not being const * fixes that cx_tree_search() did not investigate subtrees with equally good distance +* removes the use of C23 attributes because they don't mix well with GNU attributes in GCC 15 ### Version 3.1 - 2025-02-11 {collapsible="true"}
--- a/src/cx/common.h Thu Apr 17 21:45:01 2025 +0200 +++ b/src/cx/common.h Sat Apr 19 11:33:15 2025 +0200 @@ -240,20 +240,6 @@ */ #define cx_attr_access_w(...) cx_attr_access(__write_only__, __VA_ARGS__) -#if __STDC_VERSION__ >= 202300L - -/** - * Do not warn about unused variable. - */ -#define cx_attr_unused [[maybe_unused]] - -/** - * Warn about discarded return value. - */ -#define cx_attr_nodiscard [[nodiscard]] - -#else // no C23 - /** * Do not warn about unused variable. */ @@ -264,8 +250,6 @@ */ #define cx_attr_nodiscard __attribute__((__warn_unused_result__)) -#endif // __STDC_VERSION__ - // --------------------------------------------------------------------------- // MSVC specifics