Plan 9 from Bell Labs’s /usr/web/sources/contrib/fernan/nhc98/src/prelude/Char/ToUpper.hs
module Char where import IsLower toUpper :: Char -> Char toUpper c | isLower c = toEnum ((fromEnum c - fromEnum 'a') + fromEnum 'A') | otherwise = c