ComplexCompare¶
Complex comparison expr
ASR node.
Declaration¶
Syntax¶
ComplexCompare(expr left, cmpop op, expr right, ttype type, expr? value)
Arguments¶
Argument Name |
Argument Description |
---|---|
|
left side of the comparison operand |
|
right side of the comparison operand |
|
comparison operator |
|
table entry type |
|
expression value |
Return values¶
The return value is the expression that the ComplexCompare represents.
Описание¶
ComplexCompare represents complex comparison operation.
Comparison operation can be:
Less than
Greater than
Less than or equal to
Greater than or equal to
Equal to
Types¶
Only accepts integers, real constants, real exponents, floating point values as real and imaginary part of complex constant.
Examples¶
(2.1, 1.1) /= 2
ASR:
(TranslationUnit
(SymbolTable
1
{
})
[(ComplexCompare
(ComplexConstructor
(RealConstant
2.100000
(Real 4 [])
)
(RealConstant
1.100000
(Real 4 [])
)
(Complex 4 [])
(ComplexConstant
2.100000
1.100000
(Complex 4 [])
)
)
NotEq
(Cast
(IntegerConstant 2 (Integer 4 []))
IntegerToComplex
(Complex 4 [])
()
)
(Logical 4 [])
()
)]
)