summaryrefslogtreecommitdiff
path: root/source/slang/slang.cpp
diff options
context:
space:
mode:
authorYong He <yonghe@outlook.com>2024-04-12 06:59:21 -0700
committerGitHub <noreply@github.com>2024-04-12 06:59:21 -0700
commit4df7887f9e158ba0d5e3224c369459521a136bce (patch)
tree5969d514949762705a85e387bb644c100cc342fe /source/slang/slang.cpp
parentcc3e97985d879a36ed8d797d8a1cc3bf6010d9fb (diff)
Add missing astBuilder setting in `ComponentType::tryFoldIntVal`. (#3934)
Diffstat (limited to 'source/slang/slang.cpp')
-rw-r--r--source/slang/slang.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/source/slang/slang.cpp b/source/slang/slang.cpp
index 1896008b0..355da23b9 100644
--- a/source/slang/slang.cpp
+++ b/source/slang/slang.cpp
@@ -2224,6 +2224,8 @@ Dictionary<String, IntVal*>& ComponentType::getMangledNameToIntValMap()
ConstantIntVal* ComponentType::tryFoldIntVal(IntVal* intVal)
{
+ auto astBuilder = getLinkage()->getASTBuilder();
+ SLANG_AST_BUILDER_RAII(astBuilder);
return as<ConstantIntVal>(intVal->linkTimeResolve(getMangledNameToIntValMap()));
}