OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gfortran.dg/] [interface_2.f90] - Rev 858

Go to most recent revision | Compare with Previous | Blame | View Log

! { dg-do compile }
! PR fortran/24545
MODULE Compare_Float_Numbers

  IMPLICIT NONE

  INTERFACE Compare_Float
    MODULE PROCEDURE Compare_Float_Single
  END INTERFACE Compare_Float

  INTERFACE OPERATOR (.EqualTo.)
    MODULE PROCEDURE Is_Equal_To_Single
  END INTERFACE OPERATOR (.EqualTo.)

CONTAINS

  FUNCTION Is_Equal_To_Single(x, y) RESULT(Equal_To)
    REAL(4), INTENT(IN) :: x, y
    LOGICAL :: Equal_To
    Equal_To = .true.
  END FUNCTION Is_Equal_To_Single

  FUNCTION Compare_Float_Single(x, y) RESULT(Compare)
    REAL(4), INTENT(IN) :: x, y
    LOGICAL :: Compare
    Compare = .true.
  END FUNCTION Compare_Float_Single

END MODULE Compare_Float_Numbers

! { dg-final { cleanup-modules "compare_float_numbers" } }

Go to most recent revision | Compare with Previous | Blame | View Log

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.