diff options
| author | Yong He <yonghe@outlook.com> | 2024-02-09 22:00:15 -0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-02-09 22:00:15 -0800 |
| commit | 20ab16178e45d07b4dc0104a7a98865d18440b62 (patch) | |
| tree | 5314057a48d5ad2346fa808e4cfacff0991ce9b9 /source/slang/slang-check-expr.cpp | |
| parent | f44da6cc5c0f211c13bd1eb0743d79c7861ea64e (diff) | |
Support link-time constants. (#3564)
* Support link-time constants.
* Fix.
* Fix.
Diffstat (limited to 'source/slang/slang-check-expr.cpp')
| -rw-r--r-- | source/slang/slang-check-expr.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/source/slang/slang-check-expr.cpp b/source/slang/slang-check-expr.cpp index 2f4906826..c04cb73e4 100644 --- a/source/slang/slang-check-expr.cpp +++ b/source/slang/slang-check-expr.cpp @@ -1659,6 +1659,9 @@ namespace Slang return nullptr; if(!decl->hasModifier<ConstModifier>()) return nullptr; + // Extern static const is not considered compile-time constant by the front-end. + if (decl->hasModifier<ExternModifier>()) + return nullptr; if (isInterfaceRequirement(decl)) { |
