[clang] a7402b0 - [clang][NFC] Convert `Parser::ScopeCacheSize` to a constant
Vlad Serebrennikov via cfe-commits
cfe-commits at lists.llvm.org
Tue Apr 29 16:17:23 PDT 2025
Author: Vlad Serebrennikov
Date: 2025-04-30T02:17:17+03:00
New Revision: a7402b0c4ac1cc255354904ef1f46aa7b714c44f
URL: https://github.com/llvm/llvm-project/commit/a7402b0c4ac1cc255354904ef1f46aa7b714c44f
DIFF: https://github.com/llvm/llvm-project/commit/a7402b0c4ac1cc255354904ef1f46aa7b714c44f.diff
LOG: [clang][NFC] Convert `Parser::ScopeCacheSize` to a constant
Added:
Modified:
clang/include/clang/Parse/Parser.h
Removed:
################################################################################
diff --git a/clang/include/clang/Parse/Parser.h b/clang/include/clang/Parse/Parser.h
index 645df4aabc374..d9cf3813a1828 100644
--- a/clang/include/clang/Parse/Parser.h
+++ b/clang/include/clang/Parse/Parser.h
@@ -94,7 +94,7 @@ class Parser : public CodeCompletionHandler {
StackExhaustionHandler StackHandler;
/// ScopeCache - Cache scopes to reduce malloc traffic.
- enum { ScopeCacheSize = 16 };
+ static constexpr int ScopeCacheSize = 16;
unsigned NumCachedScopes;
Scope *ScopeCache[ScopeCacheSize];
More information about the cfe-commits
mailing list