Skip to content
Commit 559e816f authored by Alex Zinenko's avatar Alex Zinenko Committed by jpienaar
Browse files

Add OpTraits for operand types: IntegerLike and SameType.

Introduce new OpTraits verifying relation between operands of an Operation,
similarly to its results.  Arithmetic operations are defined separately for
integer and floating point types.  While we are currently leveraging the
equality of result and operand types to make sure the right arithmetic
operations are used for the right types, we may eventually want to verify
operand types directly.  Furthermore, for upcoming comparison operations, the
type of the result differs from those of the operands so we need to verify the
operand types directly.  Similarly, we will want to restrict comparisons (and
potentially binary arithmetic operations) to operands of the same type.

PiperOrigin-RevId: 220365629
parent 6cd5d5c5
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment