aboutsummaryrefslogblamecommitdiffstats
path: root/arch/x86/boot/isdigit.h
blob: 25e13403193cc4d0231b8ce97b49ef4fa6f4bb75 (plain) (tree)




















                                          
#ifndef BOOT_ISDIGIT_H

#define BOOT_ISDIGIT_H

static inline int isdigit(int ch)
{
	return (ch >= '0') && (ch <= '9');
}

static inline int isxdigit(int ch)
{
	if (isdigit(ch))
		return true;

	if ((ch >= 'a') && (ch <= 'f'))
		return true;

	return (ch >= 'A') && (ch <= 'F');
}

#endif