[Mlir-commits] [mlir] [mlir] Clarify type of optional operands in custom parse directive. (PR #123554)
Philipp Schilk
llvmlistbot at llvm.org
Sun Jan 19 23:11:40 PST 2025
https://github.com/schilkp created https://github.com/llvm/llvm-project/pull/123554
A custom parse directive with optional operand has an `std::optional` argument - `Optional` is not valid in this context.
>From 31f7ebcf3dbe1ba17f952674a686422181739e9e Mon Sep 17 00:00:00 2001
From: schilkp <schilk.philipp at gmail.com>
Date: Mon, 20 Jan 2025 08:05:42 +0100
Subject: [PATCH] [MLIR] Clarify type of optional operands in custom parse
directive.
A custom parse directive with optional operand has an `std::optional`
argument - `Optional` is not valid in this context.
---
mlir/docs/DefiningDialects/Operations.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/mlir/docs/DefiningDialects/Operations.md b/mlir/docs/DefiningDialects/Operations.md
index 8ff60ac21424c4..53c0ab1f08e227 100644
--- a/mlir/docs/DefiningDialects/Operations.md
+++ b/mlir/docs/DefiningDialects/Operations.md
@@ -867,7 +867,7 @@ declarative parameter to `parse` method argument is detailed below:
- Optional: `<Attribute-Storage-Type>(e.g. Attribute) &`
* Operand Variables
- Single: `OpAsmParser::UnresolvedOperand &`
- - Optional: `Optional<OpAsmParser::UnresolvedOperand> &`
+ - Optional: `std::optional<OpAsmParser::UnresolvedOperand> &`
- Variadic: `SmallVectorImpl<OpAsmParser::UnresolvedOperand> &`
- VariadicOfVariadic:
`SmallVectorImpl<SmallVector<OpAsmParser::UnresolvedOperand>> &`
More information about the Mlir-commits
mailing list