From a8c3e8c4a27f8a67e9071d782bafffdcc16389f3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20Mo=CC=88ding?= Date: Sun, 28 Apr 2024 11:57:27 +0200 Subject: [PATCH] Flag function as const --- src/scanner.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/scanner.c b/src/scanner.c index eec96e4..b6ef81c 100644 --- a/src/scanner.c +++ b/src/scanner.c @@ -78,7 +78,7 @@ typedef struct ScannerState { * name ('a'..'z', '0'..'9', '_'). */ -static inline bool is_variable_name(int32_t c) { +__attribute__((const)) static inline bool is_variable_name(int32_t c) { return ((isalpha(c) && islower(c)) || isdigit(c) || (c == U'_')); }