aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIgor Pashev <pashev.igor@gmail.com>2022-09-27 08:58:07 +0200
committerIgor Pashev <pashev.igor@gmail.com>2022-09-27 08:58:07 +0200
commit5356cbe321cb787541ecc7ca49f407f2b2861f1f (patch)
tree2bc70ad81bcbfeadaf5099f7cb627ac652e4668e
parent643f0248eaf96842d492c628f7b1195a5772e6ad (diff)
downloadmendeleev-5356cbe321cb787541ecc7ca49f407f2b2861f1f.tar.gz
Fortran: use bitwise OR in comparison
-rw-r--r--mendeleev.f909
1 files changed, 1 insertions, 8 deletions
diff --git a/mendeleev.f90 b/mendeleev.f90
index 3108b5e..c7df836 100644
--- a/mendeleev.f90
+++ b/mendeleev.f90
@@ -69,14 +69,7 @@ contains
pure integer function tolower(c)
character(len=1), intent(in) :: c
- integer :: i
-
- i = iachar(c)
- if (i >= 65 .and. i < 90) then
- tolower = i + 32
- else
- tolower = i
- endif
+ tolower = ior(32, iachar(c))
end function tolower