From 54da75f89f7183dcdf4160532994e5b40cbe3b9f Mon Sep 17 00:00:00 2001 From: Abdelrahman Date: Sat, 22 Feb 2025 15:03:13 +0000 Subject: [PATCH] Update comment for wapp_str8_lit_ro_initialiser_list --- src/core/strings/str8/str8.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/core/strings/str8/str8.h b/src/core/strings/str8/str8.h index f4e6e48..e0e4e0b 100644 --- a/src/core/strings/str8/str8.h +++ b/src/core/strings/str8/str8.h @@ -54,7 +54,8 @@ struct str8_list { .size = sizeof(STRING) - 1, \ .buf = (c8 *)STRING}) // To be used only when initialising a static storage variable in compilers that don't support -// initialisers with the syntax of wapp_str8_lit_ro +// initialisers with the syntax of wapp_str8_lit_ro (e.g. gcc). Should only be used when necessary +// and only be assigned to a Str8RO variable to avoid any attempt at modifying the string #define wapp_str8_lit_ro_initialiser_list(STRING) {.capacity = sizeof(STRING) - 1, \ .size = sizeof(STRING) - 1, \ .buf = (c8 *)STRING}