File: fgetwc.3

package info (click to toggle)
manpages-es 1.55-9
  • links: PTS
  • area: main
  • in suites: squeeze
  • size: 7,468 kB
  • ctags: 6
  • sloc: sh: 1,629; makefile: 64
file content (63 lines) | stat: -rw-r--r-- 2,348 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
.\" Copyright (c) Bruno Haible <haible@clisp.cons.org>
.\"
.\" This is free documentation; you can redistribute it and/or
.\" modify it under the terms of the GNU General Public License as
.\" published by the Free Software Foundation; either version 2 of
.\" the License, or (at your option) any later version.
.\"
.\" References consulted:
.\"   GNU glibc-2 source code and manual
.\"   Dinkumware C library reference http://www.dinkumware.com/
.\"   OpenGroup's Single Unix specification http://www.UNIX-systems.org/online.html
.\"   ISO/IEC 9899:1999
.\"
.\" Modified Tue Oct 16 23:18:40 BST 2001 by John Levon <moz@compsoc.man.ac.uk>
.\" Translated Sun Apr 23 2000 by Juan Piernas <piernas@ditec.um.es>
.\"
.TH FGETWC 3  "25 julio 1999" "GNU" "Manual del Programador de Linux"
.SH NOMBRE
fgetwc, getwc \- leen un carácter ancho de un flujo FILE
.SH SINOPSIS
.nf
.B #include <stdio.h>
.br
.B #include <wchar.h>
.sp
.BI "wint_t fgetwc (FILE* " stream ");
.BI "wint_t getwc (FILE* " stream ");
.fi
.SH DESCRIPCIÓN
La función \fBfgetwc\fP es equivalente para caracteres anchos a la función
\fBfgetc\fP. La función lee un carácter ancho de \fIstream\fP y lo devuelve
como resultado. Si se llega al final del flujo o si \fIferror(stream)\fP es
cierto, devuelve WEOF. Si se produce un error en la conversión de caracteres
anchos, asigna a \fBerrno\fP el valor \fBEILSEQ\fP y devuelve WEOF.
.PP
La función o macro \fBgetwc\fP funciona de la misma forma que \fBfgetwc\fP.
Se puede implementar como una macro y puede evaluar su argumento más de una
vez. Nunca hay razón para usarla.
.PP
Para las versiones no-bloqueantes, véase
.BR unlocked_stdio (3).
.SH "VALOR DEVUELTO"
La función \fBfgetwc\fP devuelve el siguiente carácter ancho del flujo o
WEOF.
.SH ERRORES
Aparte de los habituales, existe
.TP
.B EILSEQ
Los datos obtenidos del flujo de entrada no forman un carácter ancho válido.
.SH "CONFORME A"
ISO/ANSI C, UNIX98
.SH "VÉASE TAMBIÉN"
.BR fputwc (3),
.BR fgetws (3),
.BR ungetwc (3),
.BR unlocked_stdio (3)
.SH OBSERVACIONES
El comportamiento de \fBfgetwc\fP depende de la categoría LC_CTYPE de la
localización actual.
.PP
En ausencia de información adicional pasada a la llamada fopen, es razonable
esperar que \fBfgetwc\fP lea realmente una secuencia multibyte del flujo y
que la convierta después en un carácter ancho.