Not sure what the best way to handle this is, but maybe we should have a global dictionary instead of constructing the lookup on the fly?
julia> MLIR.IR.context!(MLIR.IR.Context()) do
dialect = MLIR.IR.get_or_load_dialect!("jlir")
sprint(show, dialect)
end
ERROR: UndefVarError: `mlirGetDialectHandle__jlir__` not defined
Stacktrace:
[1] getproperty
@ ./Base.jl:31 [inlined]
[2] MLIR.IR.DialectHandle(s::Symbol)
@ MLIR.IR ~/src/MLIR/src/IR/IR.jl:65
[3] get_or_load_dialect!(handle::MLIR.IR.DialectHandle)
@ MLIR.IR ~/src/MLIR/src/IR/IR.jl:127 [inlined]
In contrast to:
julia> MLIR.IR.context!(MLIR.IR.Context()) do
dialect = MLIR.IR.get_or_load_dialect!(MLIR.IR.DialectHandle(Brutus.BrutusAPI.mlirGetDialectHandle__jlir__()))
end
Not sure what the best way to handle this is, but maybe we should have a global dictionary instead of constructing the lookup on the fly?
In contrast to: