beanz added inline comments.
================ Comment at: clang/lib/Sema/SemaDecl.cpp:9887 + break; + case llvm::Triple::EnvironmentType::Compute: + ShaderType = HLSLShaderAttr::ShaderType::Compute; ---------------- If the `HLSLShaderAttr::ShaderType` enum is properly ordered you should be able to convert the integer value: ``` HLSLShaderAttr::ShaderType StageInteger = (HLSLShaderAttr::ShaderType)TI.getTriple().getEnvironment() - (uint32_t)llvm::Triple::Pixel; ``` Then this code doesn't need to be updated if a new shader type is added. ================ Comment at: clang/test/SemaHLSL/entry.hlsl:16 +} \ No newline at end of file ---------------- Please fix. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D124751/new/ https://reviews.llvm.org/D124751 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits