From 0a6926003fd2300858e3089fe82f421543852395 Mon Sep 17 00:00:00 2001 From: Yong He Date: Mon, 27 Mar 2023 23:00:42 -0700 Subject: Translate all composed types into tuple types in pyBind. (#2744) * Translate all composed types into tuple types in pyBind. * Delete temp file. * Fix get tuple element code emit logic. --------- Co-authored-by: Yong He --- source/slang/slang-ir.cpp | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'source/slang/slang-ir.cpp') diff --git a/source/slang/slang-ir.cpp b/source/slang/slang-ir.cpp index 6ce54a948..76e889780 100644 --- a/source/slang/slang-ir.cpp +++ b/source/slang/slang-ir.cpp @@ -3705,6 +3705,12 @@ namespace Slang return emitIntrinsicInst(type, kIROp_MakeTargetTuple, count, args); } + IRInst* IRBuilder::emitTargetTupleGetElement(IRType* elementType, IRInst* targetTupleVal, IRInst* indexVal) + { + IRInst* args[] = {targetTupleVal, indexVal}; + return emitIntrinsicInst(elementType, kIROp_GetTargetTupleElement, 2, args); + } + IRInst* IRBuilder::emitMakeTuple(UInt count, IRInst* const* args) { List types; -- cgit v1.2.3