[Mlir-commits] [mlir] [MLIR] Fix parsed integers exceeding the expected bitwidth (PR #119971)

Oleksandr Alex Zinenko llvmlistbot at llvm.org
Sun Dec 15 14:08:50 PST 2024


================
@@ -710,12 +711,36 @@ class AsmParser {
   virtual ParseResult parseFloat(const llvm::fltSemantics &semantics,
                                  APFloat &result) = 0;
 
+  /// Parse an integer value from the stream.
+  ParseResult parseInteger(APInt &result, unsigned bitWidth,
+                           IntegerType::SignednessSemantics signedness) {
+    auto loc = getCurrentLocation();
----------------
ftynse wrote:

Nit: expand auto here please.

https://github.com/llvm/llvm-project/pull/119971


More information about the Mlir-commits mailing list