OpenBSD CVS

CVS log for src/include/ctype.h


[BACK] Up to [local] / src / include

Request diff between arbitrary revisions


Default branch: MAIN


Revision 1.26 / (download) - annotate - [select for diffs], Sun Feb 4 13:03:18 2024 UTC (3 months, 1 week ago) by jca
Branch: MAIN
CVS Tags: OPENBSD_7_5_BASE, OPENBSD_7_5, HEAD
Changes since 1.25: +25 -20 lines
Diff to previous 1.25 (colored)

Move ctype.h defines to the _CTYPE_ prefix, avoids clashes with identifiers in ports

Even if those _[BCNLPSUX] defines are in the reserved namespace, some
ports make use of those identifiers and thus need pointless
headscratching and patches.  Just use a longer reserved prefix.
We can't just #undef those defines as they are used in libc.

Change similar to what NetBSD did around 2010.  Went through base builds
and an amd64 bulk build, the only fallout was lib(e)stdc++ base_ctype.h.
"make includes" will install the latest ctype.h and libstdc++ ctype_base.h.

"makes sense" deraadt@, ok sthen@ tb@

Revision 1.25 / (download) - annotate - [select for diffs], Tue Sep 5 03:16:13 2017 UTC (6 years, 8 months ago) by schwarze
Branch: MAIN
CVS Tags: OPENBSD_7_4_BASE, OPENBSD_7_4, OPENBSD_7_3_BASE, OPENBSD_7_3, OPENBSD_7_2_BASE, OPENBSD_7_2, OPENBSD_7_1_BASE, OPENBSD_7_1, OPENBSD_7_0_BASE, OPENBSD_7_0, OPENBSD_6_9_BASE, OPENBSD_6_9, OPENBSD_6_8_BASE, OPENBSD_6_8, OPENBSD_6_7_BASE, OPENBSD_6_7, OPENBSD_6_6_BASE, OPENBSD_6_6, OPENBSD_6_5_BASE, OPENBSD_6_5, OPENBSD_6_4_BASE, OPENBSD_6_4, OPENBSD_6_3_BASE, OPENBSD_6_3, OPENBSD_6_2_BASE, OPENBSD_6_2
Changes since 1.24: +112 -2 lines
Diff to previous 1.24 (colored)

New POSIX xlocale implementation written from scratch.
Complete in the sense that all POSIX *locale(3) and *_l(3) functions
are included, but in OpenBSD, we of course only really care about
LC_CTYPE and we only support ASCII and UTF-8.

With important help from kettenis@, guenther@, and jca@.
Repeated testing in ports bulk builds by naddy@.
Additional testing by jca@, sebastia@, dcoppa@, and others.
OK kettenis@ dcoppa@, and guenther@ on an earlier version.
Riding guenther@'s libc/librthread major bump.

Revision 1.24 / (download) - annotate - [select for diffs], Mon May 26 01:49:36 2014 UTC (9 years, 11 months ago) by guenther
Branch: MAIN
CVS Tags: OPENBSD_6_1_BASE, OPENBSD_6_1, OPENBSD_6_0_BASE, OPENBSD_6_0, OPENBSD_5_9_BASE, OPENBSD_5_9, OPENBSD_5_8_BASE, OPENBSD_5_8, OPENBSD_5_7_BASE, OPENBSD_5_7, OPENBSD_5_6_BASE, OPENBSD_5_6
Changes since 1.23: +41 -41 lines
Diff to previous 1.23 (colored)

Can't use a variable 'c' in a standard include; rename it to '_c'

ok deraadt@ millert@

Revision 1.23 / (download) - annotate - [select for diffs], Sun Mar 16 18:38:30 2014 UTC (10 years, 2 months ago) by guenther
Branch: MAIN
Changes since 1.22: +5 -5 lines
Diff to previous 1.22 (colored)

lint is dead (long live the lint!), so stop using it as a cpp conditional
(namespace pollution!) or talking about its opinion on code.

ok krw@

Revision 1.22 / (download) - annotate - [select for diffs], Fri Oct 1 20:10:24 2010 UTC (13 years, 7 months ago) by guenther
Branch: MAIN
CVS Tags: OPENBSD_5_5_BASE, OPENBSD_5_5, OPENBSD_5_4_BASE, OPENBSD_5_4, OPENBSD_5_3_BASE, OPENBSD_5_3, OPENBSD_5_2_BASE, OPENBSD_5_2, OPENBSD_5_1_BASE, OPENBSD_5_1, OPENBSD_5_0_BASE, OPENBSD_5_0, OPENBSD_4_9_BASE, OPENBSD_4_9
Changes since 1.21: +19 -32 lines
Diff to previous 1.21 (colored)

Now that __only_inline is in <sys/cdefs.h>, replace the local versions in
<ctype.h> and <signal.h>

ok kettenis@ millert@ deraadt@

Revision 1.21 / (download) - annotate - [select for diffs], Sun Jul 25 15:35:29 2010 UTC (13 years, 9 months ago) by kettenis
Branch: MAIN
CVS Tags: OPENBSD_4_8_BASE, OPENBSD_4_8
Changes since 1.20: +2 -2 lines
Diff to previous 1.20 (colored)

When using GCC, we always want GNU inline semantics.  Fixes issues with
-Wsystem-headers and -std=c99, where GCC 4.2 would warn that it couldn't
give us C99 inline semantics.

ok guenther@, dcoppa@, millert@, deraadt@

Revision 1.20 / (download) - annotate - [select for diffs], Sat Mar 17 21:38:14 2007 UTC (17 years, 2 months ago) by espie
Branch: MAIN
CVS Tags: OPENBSD_4_7_BASE, OPENBSD_4_7, OPENBSD_4_6_BASE, OPENBSD_4_6, OPENBSD_4_5_BASE, OPENBSD_4_5, OPENBSD_4_4_BASE, OPENBSD_4_4, OPENBSD_4_3_BASE, OPENBSD_4_3, OPENBSD_4_2_BASE, OPENBSD_4_2
Changes since 1.19: +5 -1 lines
Diff to previous 1.19 (colored)

allow extern inline stuff to proceed unchanged thru the mess that the
combined GCC and ISO committees managed to make out of it.

With this, gcc >= 4.3 can grok its way through it correctly.

okay kettenis@, with some help figuring stuff out.

Revision 1.19 / (download) - annotate - [select for diffs], Tue Dec 13 00:35:22 2005 UTC (18 years, 5 months ago) by millert
Branch: MAIN
CVS Tags: OPENBSD_4_1_BASE, OPENBSD_4_1, OPENBSD_4_0_BASE, OPENBSD_4_0, OPENBSD_3_9_BASE, OPENBSD_3_9
Changes since 1.18: +13 -5 lines
Diff to previous 1.18 (colored)

First step in include files overhaul.  Use __FOO_VISIBLE (as defined
in sys/cdefs.h) instead of _FOO_SOURCE.  Also fix several namespace
pollution issues, including the byte order defines.  OK deraadt@

Revision 1.18 / (download) - annotate - [select for diffs], Mon Aug 8 05:53:00 2005 UTC (18 years, 9 months ago) by espie
Branch: MAIN
CVS Tags: OPENBSD_3_8_BASE, OPENBSD_3_8
Changes since 1.17: +3 -3 lines
Diff to previous 1.17 (colored)

activate LC_CTYPE for 8 bits locale.
Make sure tolower/toupper use the whole 8 bits.

okay deraadt@
thanks to everyone who tested

Revision 1.17 / (download) - annotate - [select for diffs], Fri Apr 2 22:37:12 2004 UTC (20 years, 1 month ago) by avsm
Branch: MAIN
CVS Tags: OPENBSD_3_7_BASE, OPENBSD_3_7, OPENBSD_3_6_BASE, OPENBSD_3_6
Changes since 1.16: +2 -2 lines
Diff to previous 1.16 (colored)

fix non-gnu ansi compilers by not using 'inline' but '__inline' instead.
lets tendra build again.
ok deraadt@, pvalchev@, millert@

Revision 1.16 / (download) - annotate - [select for diffs], Thu Jan 15 20:01:27 2004 UTC (20 years, 4 months ago) by millert
Branch: MAIN
CVS Tags: OPENBSD_3_5_BASE, OPENBSD_3_5
Changes since 1.15: +5 -5 lines
Diff to previous 1.15 (colored)

If lint is defined, act like _ANSI_LIBRARY was defined.  That way
lint gets the prototypes it expects and doesn't get confused by the
inline functions.  OK deraadt@

Revision 1.15 / (download) - annotate - [select for diffs], Tue Jan 13 15:47:24 2004 UTC (20 years, 4 months ago) by millert
Branch: MAIN
Changes since 1.14: +31 -19 lines
Diff to previous 1.14 (colored)

Allow this to compile on non-gcc.  OK deraadt@ art@

Revision 1.14 / (download) - annotate - [select for diffs], Tue Jun 10 22:00:31 2003 UTC (20 years, 11 months ago) by millert
Branch: MAIN
CVS Tags: OPENBSD_3_4_BASE, OPENBSD_3_4
Changes since 1.13: +38 -37 lines
Diff to previous 1.13 (colored)

Remove an extraneous "& 0xff" (the cast to unsigned char is sufficient).

Use "extern __inline" instead of "static __inline" since the extern
flavor behaves more like a macro (which is what we want).

OK deraadt@ and tested on all platforms by various folks.

Revision 1.13 / (download) - annotate - [select for diffs], Mon Jun 2 19:34:12 2003 UTC (20 years, 11 months ago) by millert
Branch: MAIN
Changes since 1.12: +2 -6 lines
Diff to previous 1.12 (colored)

Remove the advertising clause in the UCB license which Berkeley
rescinded 22 July 1999.  Proofed by myself and Theo.

Revision 1.12 / (download) - annotate - [select for diffs], Mon Dec 30 21:36:05 2002 UTC (21 years, 4 months ago) by millert
Branch: MAIN
CVS Tags: OPENBSD_3_3_BASE, OPENBSD_3_3
Changes since 1.11: +12 -16 lines
Diff to previous 1.11 (colored)

Back out __EOF stuff and just use -1 in ctype.h.  This is OK since
we don't want any user defines to change how the inlined ctype
functions behave.

Revision 1.11 / (download) - annotate - [select for diffs], Sun Dec 29 03:02:35 2002 UTC (21 years, 4 months ago) by millert
Branch: MAIN
Changes since 1.10: +15 -13 lines
Diff to previous 1.10 (colored)

Don't define EOF In ctype.h, some 3rd party code checks whether or
not EOF is defined to determine if stdio.h has been included.
Instead, use __EOF which should be OK wrt namespace safety.

Revision 1.10 / (download) - annotate - [select for diffs], Sun Dec 15 13:53:39 2002 UTC (21 years, 5 months ago) by millert
Branch: MAIN
Changes since 1.9: +12 -12 lines
Diff to previous 1.9 (colored)

Casting to unsigned int in isfoo() causes problems on alpha and
sparc64.  Change cast back to unsigned char but do a bitwise AND
with 0xff to avoid any sign extension weirdness and to make it
impossible for us to overflow _C_ctype_.  The bitwise AND is probably
not needed and may be removed later if this does not trigger compiler bugs.

Revision 1.9 / (download) - annotate - [select for diffs], Sat Dec 14 14:26:19 2002 UTC (21 years, 5 months ago) by millert
Branch: MAIN
Changes since 1.8: +2 -2 lines
Diff to previous 1.8 (colored)

fix typo; noticed by David Krause

Revision 1.8 / (download) - annotate - [select for diffs], Sat Dec 14 02:34:38 2002 UTC (21 years, 5 months ago) by millert
Branch: MAIN
Changes since 1.7: +12 -34 lines
Diff to previous 1.7 (colored)

Instead of doing "if (c == EOF) return 0;" use the hook ('?') operator
instead to make these one-liners.  Works around a compiler bug on vax
that affects both the libc and inline versions identically.

Revision 1.7 / (download) - annotate - [select for diffs], Fri Dec 13 23:16:38 2002 UTC (21 years, 5 months ago) by millert
Branch: MAIN
Changes since 1.6: +4 -6 lines
Diff to previous 1.6 (colored)

Less stupid check for 7-bit ascii in toupper/tolower
Remove useless check for EOF in isascii

Revision 1.6 / (download) - annotate - [select for diffs], Fri Dec 13 22:39:27 2002 UTC (21 years, 5 months ago) by millert
Branch: MAIN
Changes since 1.5: +15 -15 lines
Diff to previous 1.5 (colored)

Cast to unsigned int, not unsigned char, since what is being cast is an
int, not a char.

Revision 1.5 / (download) - annotate - [select for diffs], Wed Dec 11 23:01:40 2002 UTC (21 years, 5 months ago) by millert
Branch: MAIN
Changes since 1.4: +142 -39 lines
Diff to previous 1.4 (colored)

Convert ctype.h macros into inline functions.  This fixes the issues we
currently have with the macro versions and makes the ctype.h versions
100% identical to what is in libc.
Discussed with pjanzen@ and OK'd by deraadt@.

Revision 1.4 / (download) - annotate - [select for diffs], Sat Feb 16 21:27:17 2002 UTC (22 years, 3 months ago) by millert
Branch: MAIN
CVS Tags: OPENBSD_3_2_BASE, OPENBSD_3_2, OPENBSD_3_1_BASE, OPENBSD_3_1
Changes since 1.3: +19 -19 lines
Diff to previous 1.3 (colored)

Part one of userland __P removal.  Done with a simple regexp with some minor hand editing to make comments line up correctly.  Another pass is forthcoming that handles the cases that could not be done automatically.

Revision 1.3 / (download) - annotate - [select for diffs], Thu Apr 30 05:49:21 1998 UTC (26 years ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_3_0_BASE, OPENBSD_3_0, OPENBSD_2_9_BASE, OPENBSD_2_9, OPENBSD_2_8_BASE, OPENBSD_2_8, OPENBSD_2_7_BASE, OPENBSD_2_7, OPENBSD_2_6_BASE, OPENBSD_2_6, OPENBSD_2_5_BASE, OPENBSD_2_5, OPENBSD_2_4_BASE, OPENBSD_2_4
Changes since 1.2: +16 -16 lines
Diff to previous 1.2 (colored)

make ctype macros on char 0x82 and such work

Revision 1.2 / (download) - annotate - [select for diffs], Sun Sep 21 10:45:28 1997 UTC (26 years, 8 months ago) by niklas
Branch: MAIN
CVS Tags: OPENBSD_2_3_BASE, OPENBSD_2_3, OPENBSD_2_2_BASE, OPENBSD_2_2
Changes since 1.1: +1 -0 lines
Diff to previous 1.1 (colored)

Well, as we are heading for a release people are encouraged to rebuild their
entire trees for testing anyway, I might as well do this intrusive touching
of include files now.  Added openBSD tags.

Revision 1.1.1.1 / (download) - annotate - [select for diffs] (vendor branch), Wed Oct 18 08:41:12 1995 UTC (28 years, 7 months ago) by deraadt
CVS Tags: netbsd_1_1, OPENBSD_2_1_BASE, OPENBSD_2_1, OPENBSD_2_0_BASE, OPENBSD_2_0
Changes since 1.1: +0 -0 lines
Diff to previous 1.1 (colored)

initial import of NetBSD tree

Revision 1.1 / (download) - annotate - [select for diffs], Wed Oct 18 08:41:12 1995 UTC (28 years, 7 months ago) by deraadt
Branch: MAIN

Initial revision

This form allows you to request diff's between any two revisions of a file. You may select a symbolic revision name using the selection box or you may type in a numeric name using the type-in text box.