summaryrefslogtreecommitdiff
path: root/source/core/slang-char-util.h
diff options
context:
space:
mode:
Diffstat (limited to 'source/core/slang-char-util.h')
-rw-r--r--source/core/slang-char-util.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/source/core/slang-char-util.h b/source/core/slang-char-util.h
index f831f6d55..40abee602 100644
--- a/source/core/slang-char-util.h
+++ b/source/core/slang-char-util.h
@@ -30,6 +30,8 @@ struct CharUtil
/// True if it's alpha
SLANG_FORCE_INLINE static bool isAlpha(char c) { return (getFlags(c) & (Flag::Upper | Flag::Lower)) != 0; }
+ /// True if it's alpha or a digit
+ SLANG_FORCE_INLINE static bool isAlphaOrDigit(char c) { return (getFlags(c) & (Flag::Upper | Flag::Lower | Flag::Digit)) != 0; }
/// True if the character is a valid hex character
SLANG_FORCE_INLINE static bool isHexDigit(char c) { return (getFlags(c) & Flag::HexDigit) != 0; }