Skip to content

Commit 4ba535b

Browse files
Tzung-Han Juangerick-xanadu
andauthored
Update mlir/lib/Dialect/Bufferization/Transforms/OneShotModuleBufferize.cpp
Co-authored-by: erick-xanadu <[email protected]>
1 parent 074192c commit 4ba535b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

mlir/lib/Dialect/Bufferization/Transforms/OneShotModuleBufferize.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -349,7 +349,7 @@ getFuncOpsOrderedByCalls(ModuleOp moduleOp,
349349
/// entire function body, a more concise memref type can potentially be used for
350350
/// the return type of the function.
351351
static void foldMemRefCasts(FunctionOpInterface funcOp) {
352-
if (funcOp.getFunctionBody().empty() || funcOp.getNumResults() == 0)
352+
if (funcOp.getFunctionBody().empty())
353353
return;
354354

355355
Operation *returnOp = getAssumedUniqueReturnOp(funcOp);

0 commit comments

Comments
 (0)