summaryrefslogtreecommitdiffstats
path: root/source/slang/compiler.h
diff options
context:
space:
mode:
authorYong He <yongh@outlook.com>2018-01-03 17:15:03 -0800
committerYong He <yongh@outlook.com>2018-01-03 17:15:03 -0800
commit550405d2de2ca617046e73fe5ec7e5e1765a5c97 (patch)
tree89b1e0e3f0e95ea0bf586bd67fa36066f0021ce7 /source/slang/compiler.h
parent61b206db5fc5a4c9d42fa3fbb4f50624b6c6c6c5 (diff)
Fix type lookup of global type arguments
Global type argument lookup should be done in both loaded modules and current trnaslation units. This is the same as the logic of spReflection_FindTypeByName, so it is extracted into `CompileRequest::lookupGlobalDecl(Name*)` method and reused in places.
Diffstat (limited to 'source/slang/compiler.h')
-rw-r--r--source/slang/compiler.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/source/slang/compiler.h b/source/slang/compiler.h
index 2302c77c0..1fca4751c 100644
--- a/source/slang/compiler.h
+++ b/source/slang/compiler.h
@@ -373,6 +373,8 @@ namespace Slang
Name* name,
SourceLoc const& loc);
+ Decl* lookupGlobalDecl(Name* name);
+
SourceManager* getSourceManager()
{
return sourceManager;