]> git.ipfire.org Git - thirdparty/man-pages.git/blame - man3/ecvt_r.3
Added/updated glibc feature test macro requirements
[thirdparty/man-pages.git] / man3 / ecvt_r.3
CommitLineData
fea681da
MK
1.\" Copyright (C) 2002 Andries Brouwer <aeb@cwi.nl>
2.\"
3.\" Permission is granted to make and distribute verbatim copies of this
4.\" manual provided the copyright notice and this permission notice are
5.\" preserved on all copies.
6.\"
7.\" Permission is granted to copy and distribute modified versions of this
8.\" manual under the conditions for verbatim copying, provided that the
9.\" entire resulting derived work is distributed under the terms of a
10.\" permission notice identical to this one.
c13182ef 11.\"
fea681da
MK
12.\" Since the Linux kernel and libraries are constantly changing, this
13.\" manual page may be incorrect or out-of-date. The author(s) assume no
14.\" responsibility for errors or omissions, or for damages resulting from
15.\" the use of the information contained herein. The author(s) may not
16.\" have taken the same level of care in the production of this manual,
17.\" which is licensed free of charge, as they might when working
18.\" professionally.
c13182ef 19.\"
fea681da
MK
20.\" Formatted or processed versions of this manual, if unaccompanied by
21.\" the source, must acknowledge the copyright and authors of this work.
22.\"
23.\" This replaces an earlier man page written by Walter Harms
24.\" <walter.harms@informatik.uni-oldenburg.de>.
25.\"
26.\" Corrected return types; from Fabian; 2004-10-05
27.\"
cc4615cc 28.TH ECVT_R 3 2007-07-26 "GNU" "Linux Programmer's Manual"
fea681da
MK
29.SH NAME
30ecvt_r, fcvt_r, qecvt_r, qfcvt_r \- convert a floating-point number to a string
31.SH SYNOPSIS
b9f02710 32.nf
fea681da
MK
33.B #include <stdlib.h>
34.sp
35.BI "int ecvt_r(double " number ", int " ndigits ", int *" decpt ,
b9f02710 36.BI " int *" sign ", char *" buf ", size_t " len );
fea681da
MK
37.sp
38.BI "int fcvt_r(double " number ", int " ndigits ", int *" decpt ,
b9f02710 39.BI " int *" sign ", char *" buf ", size_t " len );
fea681da
MK
40.sp
41.BI "int qecvt_r(long double " number ", int " ndigits ", int *" decpt ,
b9f02710 42.BI " int *" sign ", char *" buf ", size_t " len );
fea681da
MK
43.sp
44.BI "int qfcvt_r(long double " number ", int " ndigits ", int *" decpt ,
b9f02710
MK
45.BI " int *" sign ", char *" buf ", size_t " len );
46.fi
cc4615cc
MK
47.sp
48.in -4n
49Feature Test Macro Requirements for glibc (see
50.BR feature_test_macros (7)):
51.in
52.sp
53.BR ecvt_r (),
54.BR fcvt_r (),
55.BR qecvt_r (),
56.BR qfcvt_r ():
57.br
58_SVID_SOURCE || _BSD_SOURCE || _XOPEN_SOURCE\ >=\ 500
fea681da
MK
59.SH DESCRIPTION
60The functions
e511ffb6
MK
61.BR ecvt_r (),
62.BR fcvt_r (),
63.BR qecvt_r ()
fea681da 64and
e511ffb6 65.BR qfcvt_r ()
fea681da 66are identical to
f19a0f03
MK
67.BR ecvt (),
68.BR fcvt (),
69.BR qecvt ()
fea681da 70and
f19a0f03 71.BR qfcvt (),
fea681da
MK
72respectively, except that they do not return their result in a static
73buffer, but instead use the supplied
74.I buf
75of size
76.IR len .
77See
78.BR ecvt (3)
79and
80.BR qecvt (3).
81.SH "RETURN VALUE"
82These functions return 0 on success, and \-1 otherwise.
2b2581ee
MK
83.SH "CONFORMING TO"
84These functions are GNU extensions.
fea681da 85.SH NOTES
c13182ef
MK
86These functions are obsolete.
87Instead,
fb186734 88.BR sprintf (3)
fea681da 89is recommended.
fea681da
MK
90.SH "SEE ALSO"
91.BR ecvt (3),
92.BR qecvt (3),
93.BR sprintf (3)