summaryrefslogtreecommitdiffstats
path: root/mdk-stage1/dietlibc/lib/toupper.c
blob: f7d415e957b199fdcf9bbb1d966086ab3f0edee8 (plain)
1
2
3
4
5
6
7
8
#include <ctype.h>

inline int toupper(int ch) {
  if ( (unsigned int)(ch - 'a') < 26u )
    ch += 'A' - 'a';
  return ch;
}