[Mlir-commits] [mlir] [mlir] Add support for DIGlobalVariable and DIGlobalVariableExpression (PR #73367)
Billy Zhu
llvmlistbot at llvm.org
Fri Nov 24 17:36:45 PST 2023
================
@@ -455,7 +456,7 @@ def LLVM_DbgDeclareOp : LLVM_DbgIntrOp<"dbg.declare", "addr",
let arguments = (ins
LLVM_AnyPointer:$addr,
LLVM_DILocalVariableAttr:$varInfo,
- DefaultValuedAttr<LLVM_DIExpressionAttr, "std::nullopt">:$locationExpr
+ OptionalAttr<LLVM_DIExpressionAttr>:$locationExpr
----------------
zyx-billy wrote:
This may be a personal preference, but would a DefaultValuedAttr be simpler here for the semantics of the op? That way there's only one way to represent an empty expression, so the user doesn't have to check/maintain when getting/setting.
https://github.com/llvm/llvm-project/pull/73367
More information about the Mlir-commits
mailing list