diff options
author | Valentin Clement <clementval@gmail.com> | 2022-06-24 09:10:03 +0200 |
---|---|---|
committer | Valentin Clement <clementval@gmail.com> | 2022-06-24 09:10:18 +0200 |
commit | aeb2cd3176b03c3f186ca5d3ae6bd08d2ba77227 (patch) | |
tree | cc025d99a5a2501489eb3b85dbd773895e959465 /flang/module | |
parent | 753b766deaa2d9baab2e7dad7ce02ae2e08a0a24 (diff) | |
download | llvm-aeb2cd3176b03c3f186ca5d3ae6bd08d2ba77227.tar.gz |
[flang] Keep PURE in IEEE functions
PURE keyword should be kept in `__fortran_ieee_exceptions.f90`
and `ieee_arithmetic.f90` and not removed as done in
https://reviews.llvm.org/D128431
Reviewed By: vdonaldson
Differential Revision: https://reviews.llvm.org/D128498
Diffstat (limited to 'flang/module')
-rw-r--r-- | flang/module/__fortran_ieee_exceptions.f90 | 4 | ||||
-rw-r--r-- | flang/module/ieee_arithmetic.f90 | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/flang/module/__fortran_ieee_exceptions.f90 b/flang/module/__fortran_ieee_exceptions.f90 index 7232bbf53cd6..0b620f55cee8 100644 --- a/flang/module/__fortran_ieee_exceptions.f90 +++ b/flang/module/__fortran_ieee_exceptions.f90 @@ -124,13 +124,13 @@ module __Fortran_ieee_exceptions end interface #define IEEE_SUPPORT_FLAG_R(XKIND) \ - logical function ieee_support_flag_a##XKIND(flag, x); \ + pure logical function ieee_support_flag_a##XKIND(flag, x); \ import ieee_flag_type; \ type(ieee_flag_type), intent(in) :: flag; \ real(XKIND), intent(in) :: x(..); \ end function ieee_support_flag_a##XKIND; interface ieee_support_flag - logical function ieee_support_flag(flag) + pure logical function ieee_support_flag(flag) import ieee_flag_type type(ieee_flag_type), intent(in) :: flag end function ieee_support_flag diff --git a/flang/module/ieee_arithmetic.f90 b/flang/module/ieee_arithmetic.f90 index b2ac217aa86a..365f803aca71 100644 --- a/flang/module/ieee_arithmetic.f90 +++ b/flang/module/ieee_arithmetic.f90 @@ -514,7 +514,7 @@ module ieee_arithmetic real(XKIND), intent(in) :: x(..); \ end function ieee_support_rounding_a##XKIND; interface ieee_support_rounding - logical function ieee_support_rounding(round_value) + pure logical function ieee_support_rounding(round_value) import ieee_round_type type(ieee_round_type), intent(in) :: round_value end function ieee_support_rounding |