Class Numeric32BitSub
- java.lang.Object
-
- it.unive.lisa.symbolic.value.operator.binary.Numeric32BitSub
-
- All Implemented Interfaces:
Operator,ArithmeticOperator,BinaryOperator,OverflowingOperator,SubtractionOperator
public class Numeric32BitSub extends java.lang.Object implements SubtractionOperator, OverflowingOperator, BinaryOperator
Given two expressions that both evaluate to numeric values, aBinaryExpressionusing this operator computes the arithmetic subtraction of those values. Both arguments and results are expected to be 32-bits numbers, and this operation thus can overflow/underflow.
First argument expression type:NumericType(32-bit)
Second argument expression type:NumericType(32-bit)
Computed expression type:NumericType(32-bit)
-
-
Field Summary
Fields Modifier and Type Field Description static Numeric32BitSubINSTANCEThe singleton instance of this class.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringtoString()ExternalSet<Type>typeInference(ExternalSet<Type> left, ExternalSet<Type> right)Computes the runtime types of this expression (i.e., of the result of this expression) assuming that the arguments of this expression have the given types.
-
-
-
Field Detail
-
INSTANCE
public static final Numeric32BitSub INSTANCE
The singleton instance of this class.
-
-
Method Detail
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
typeInference
public ExternalSet<Type> typeInference(ExternalSet<Type> left, ExternalSet<Type> right)
Description copied from interface:BinaryOperatorComputes the runtime types of this expression (i.e., of the result of this expression) assuming that the arguments of this expression have the given types.- Specified by:
typeInferencein interfaceBinaryOperator- Parameters:
left- the set of types of the left-most argument of this expressionright- the set of types of the right-most argument of this expression- Returns:
- the runtime types of this expression
-
-