Skip to content

Commit 321962c

Browse files
committed
[FIX][TIRx] Preserve nested dictionary attribute nodes
1 parent e428d20 commit 321962c

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

‎src/tirx/script/printer/expr.cc‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -259,7 +259,10 @@ ExprDoc CallAttrsDoc(const ffi::Any& value, const AccessPath& p, const IRDocsifi
259259
{CallAttrsDoc(tuple.value()->fields, p->Attr("fields"), d)});
260260
}
261261
if (const auto* attrs = value.as<DictAttrsNode>()) {
262-
return CallAttrsDoc(attrs->dict, p->Attr("dict"), d);
262+
return IdDoc("tvm")
263+
->Attr("ir")
264+
->Attr("DictAttrs")
265+
->Call({CallAttrsDoc(attrs->dict, p->Attr("dict"), d)});
263266
}
264267
if (auto array = value.as<ffi::Array<ffi::Any>>()) {
265268
ffi::Array<ExprDoc> items;

0 commit comments

Comments
 (0)