Deprecate the rest of the rune interface.

This commit is contained in:
Tim J. Robbins 2002-09-18 06:19:12 +00:00
parent 7948cae0d2
commit 530bb9225d
2 changed files with 22 additions and 0 deletions

View File

@ -45,6 +45,7 @@ __FBSDID("$FreeBSD$");
#include <stddef.h>
#include <stdio.h>
__warn_references(fgetrune, "warning: fgetrune() is deprecated. See fgetrune(3).");
long
fgetrune(fp)
FILE *fp;
@ -72,6 +73,7 @@ fgetrune(fp)
return (_INVALID_RUNE);
}
__warn_references(fungetrune, "warning: fungetrune() is deprecated. See fungetrune(3).");
int
fungetrune(r, fp)
rune_t r;
@ -87,6 +89,7 @@ fungetrune(r, fp)
return (0);
}
__warn_references(fputrune, "warning: fputrune() is deprecated. See fputrune(3).");
int
fputrune(r, fp)
rune_t r;

View File

@ -69,6 +69,25 @@
.Ft int
.Fn fputrune "rune_t rune" "FILE *stream"
.Sh DESCRIPTION
.Bf Em
The
.Bx 4.4
.Dq rune
functions have been deprecated in favour of the
.Tn ISO
C99 extended multibyte and wide character facilities
and should not be used in new applications.
.Ef
Consider using
.Xr setlocale 3 ,
.Xr mbrtowc 3 ,
.Xr wcrtomb 3 ,
.Xr fgetwc 3 ,
.Xr ungetwc 3 ,
and
.Xr fputwc 3
instead.
.Pp
The
.Fn setrunelocale
controls the type of encoding used to represent runes as multibyte strings