Implement ==
operator.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(key_morton), | intent(in) | :: | lhs | Left hand side. |
||
class(*), | intent(in) | :: | rhs | Rigth hand side. |
elemental logical function is_equal(lhs, rhs)
!---------------------------------------------------------------------------------------------------------------------------------
!< Implement `==` operator.
!---------------------------------------------------------------------------------------------------------------------------------
class(key_morton), intent(in) :: lhs !< Left hand side.
class(*), intent(in) :: rhs !< Rigth hand side.
!---------------------------------------------------------------------------------------------------------------------------------
!---------------------------------------------------------------------------------------------------------------------------------
is_equal = .false.
select type(rhs)
type is(key_morton)
is_equal = lhs%key==rhs%key
endselect
!---------------------------------------------------------------------------------------------------------------------------------
endfunction is_equal