Files
clang-p2996/mlir/test/Analysis/invalid.mlir
Kai Sasaki de58a4f163 [mlir][Analysis] Guard data flow analysis from no block function
Foo analysis for testing the data flow analysis does not support the region without any block. Although that analysis is assumed to be used for testing purpose, it is generally better to be explicit about the scope the framework supports.

The original issue was reported here.
https://github.com/llvm/llvm-project/issues/60580

Reviewed By: springerm

Differential Revision: https://reviews.llvm.org/D144359
2023-02-22 15:20:11 +09:00

8 lines
254 B
MLIR

// RUN: mlir-opt -split-input-file -pass-pipeline='builtin.module(func.func(test-foo-analysis))' %s -verify-diagnostics
// -----
// expected-error @+1 {{expected at least one block in the region}}
func.func private @no_block_func_declaration() -> ()