After create FuncOp at the front block of moduleOp, can't see it at the mlir file

Hi
meet one problem:
auto module = SymbolTable::getNearestSymbolTable(funcOp);
builder.setInsertionPointToStart(&module->getRegion(0).front());
auto fnOp66 = mlir::func::FuncOp::create(…);

at the mlir file, don’t see the fnOp66,

but if use funcOp->getParentOfTypemlir::ModuleOp().push_back(fnOp66), can see the fnOp66.

auto fnOp66 = mlir::func::FuncOp::create(…);

There is no connection between this and the builder here, you didn’t use it. Look for using the builder.create<FuncOp>(...); method instead.

it works finely, do it use MLIRContext connect the builder with op? thanks a lot

There is not connection to the builder other than using the builder explicitly as shown above (not sure I understood the question correctly).

The builder has a pointer to the context: you can look at the implementation of the create method in the OpBuilder, it is pretty simple.
It calls another create with is a one-line implementation here.

clearly now, thanks a lot