LLZK 0.1.0
Veridise's ZK Language IR
Loading...
Searching...
No Matches
OpInterfaces.h
Go to the documentation of this file.
1//===-- OpInterfaces.h ------------------------------------------*- C++ -*-===//
2//
3// Part of the LLZK Project, under the Apache License v2.0.
4// See LICENSE.txt for license information.
5// Copyright 2025 Veridise Inc.
6// SPDX-License-Identifier: Apache-2.0
7//
8//===----------------------------------------------------------------------===//
9
10#pragma once
11
12#include <mlir/IR/OpDefinition.h>
13#include <mlir/IR/Operation.h>
14#include <mlir/IR/Visitors.h>
15
16// Include TableGen'd declarations
18
19namespace llzk::constrain {
20
21inline bool containsConstraintOp(mlir::Operation *op) {
22 return op->walk([](ConstraintOpInterface) {
23 return mlir::WalkResult::interrupt();
24 }).wasInterrupted();
25}
26
27} // namespace llzk::constrain
bool containsConstraintOp(mlir::Operation *op)