summaryrefslogtreecommitdiff
path: root/source/slang-capture-replay/slang-entrypoint.cpp
diff options
context:
space:
mode:
authorYong He <yonghe@outlook.com>2024-07-10 14:09:18 -0700
committerGitHub <noreply@github.com>2024-07-10 14:09:18 -0700
commitb89421cb3b803165455020f5b70d582b6aec6e76 (patch)
tree461327ffbb55e7cea0ca73ae11cfa18425c904a8 /source/slang-capture-replay/slang-entrypoint.cpp
parent45ef0ce906c93c16495755fec2e597573e8631c4 (diff)
Add reflection API for functions. (#4587)
* Add reflection API for functions. This change adds `SlangFunctionReflection` type in the reflection API that provides methods for querying function result type, parameters and user-defined attributes. `ProgramLayout::findFunctionByName` can now find a function with the given name and returns a `FunctionReflection`. `IEntryPoint` now has a `getFunctionReflection` method that returns an `FunctionReflection` for the entrypoint. * More modifiers; make reflection API consistent.
Diffstat (limited to 'source/slang-capture-replay/slang-entrypoint.cpp')
-rw-r--r--source/slang-capture-replay/slang-entrypoint.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/source/slang-capture-replay/slang-entrypoint.cpp b/source/slang-capture-replay/slang-entrypoint.cpp
index c8ce7a663..46d701f98 100644
--- a/source/slang-capture-replay/slang-entrypoint.cpp
+++ b/source/slang-capture-replay/slang-entrypoint.cpp
@@ -304,4 +304,10 @@ namespace SlangCapture
return res;
}
+
+ SLANG_NO_THROW slang::FunctionReflection* EntryPointCapture::getFunctionReflection()
+ {
+ return m_actualEntryPoint->getFunctionReflection();
+ }
+
}