[PATCH] D135595: [HLSL] Add utility to convert environment to stage

Justin Bogner via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Oct 12 12:25:41 PDT 2022


bogner accepted this revision.
bogner added a comment.
This revision is now accepted and ready to land.

Even without the tooling aspect the addition of the static asserts is a strict improvement. looks good, thanks!



================
Comment at: clang/include/clang/Basic/HLSLRuntime.h:39
+  return static_cast<ShaderStage>(Pipeline);
+}
+
----------------
You're not actually introducing the dependency here (it was already there), but neither `ShaderStage` in LangOptions.h nor the shader stage `EnvironmentType` in Triple.h mention that they need to be kept in sync with the other. Can you add comments to both that note the relationship?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D135595/new/

https://reviews.llvm.org/D135595



More information about the cfe-commits mailing list