Common: adds more gcc constrants

This commit is contained in:
李通洲
2026-09-17 21:00:36 +08:00
parent 6ff7f2772b
commit 97ac94eb44
29 changed files with 344 additions and 285 deletions
+1 -1
View File
@@ -3,7 +3,7 @@
#include "fastfetch.h"
#include "common/time.h"
static inline const char* ffFindFileName(const char* file) {
[[gnu::nonnull(1), gnu::pure, nodiscard]] static inline const char* ffFindFileName(const char* file) {
const char* lastSlash = __builtin_strrchr(file, '/');
#ifdef _WIN32
if (lastSlash == nullptr) {