[comp.bugs.sys5] ctype

amos@nsc.nsc.com (Amos Shapir NSTA) (02/21/88)

The is...() macros are only valid to test the type of ASCII values;
that's what the isascii() macro is for.

The correct usage is:
	if(isascii(c) && isdigit(c)) ...

and that's how it should be fixed in vi.
(See K&R p.127 or H&S p. 291).

-- 
	Amos Shapir				My other CPU is a NS32532
National Semiconductor 7C/266  1135 Kern st. Sunnyvale (408) 721-8161
amos@nsc.com till March 1, 88; Then back to amos%taux01@nsc.com