1//===-- Types.td -------------------------------------------*- tablegen -*-===//
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
8//===----------------------------------------------------------------------===//
10#ifndef LLZK_SHARED_TYPES
11#define LLZK_SHARED_TYPES
13include "mlir/IR/AttrTypeBase.td"
15def AnyLLZKType : Type<CPred<"::llzk::isValidType($_self)">,
16 "a valid LLZK type", "::mlir::Type">;
18def GlobalDefType : Type<CPred<"::llzk::isValidGlobalType($_self)">,
19 "any LLZK type except non-constant types">;
21def EmitEqType : Type<CPred<"::llzk::isValidEmitEqType($_self)">,
22 "any LLZK type, excluding struct and string types">;
24def ConstReadType : Type<CPred<"::llzk::isValidConstReadType($_self)">,
25 "integral, felt, or typevar type">;
27def AnyLLZKIntType : AnyTypeOf<[I1, Index]>;
29#endif // LLZK_SHARED_TYPES