xref: /netbsd-src/lib/libc/stdio/scanf_l.3 (revision 841722be1c2ff4c9679e854665a4448959b929d3)
1.\"	$NetBSD: scanf_l.3,v 1.1 2015/12/29 17:55:23 christos Exp $
2.\" Copyright (c) 2012 Isabell Long <issyl0@FreeBSD.org>
3.\" All rights reserved.
4.\"
5.\" Redistribution and use in source and binary forms, with or without
6.\" modification, are permitted provided that the following conditions
7.\" are met:
8.\" 1. Redistributions of source code must retain the above copyright
9.\"    notice, this list of conditions and the following disclaimer.
10.\" 2. Redistributions in binary form must reproduce the above copyright
11.\"    notice, this list of conditions and the following disclaimer in the
12.\"    documentation and/or other materials provided with the distribution.
13.\"
14.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
15.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
16.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
17.\" ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
18.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
19.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
20.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24.\" SUCH DAMAGE.
25.\"
26.\" $FreeBSD: head/lib/libc/stdio/scanf_l.3 258245 2013-11-17 02:03:45Z eadler $
27.\"
28.Dd December 29, 2015
29.Dt SCANF_L 3
30.Os
31.Sh NAME
32.Nm scanf_l ,
33.Nm fscanf_l ,
34.Nm sscanf_l ,
35.Nm vfscanf_l ,
36.Nm vscanf_l ,
37.Nm vsscanf_l
38.Nd input format conversion
39.Sh LIBRARY
40.Lb libc
41.Sh SYNOPSIS
42.In stdio.h
43.In locale.h
44.Ft int
45.Fn scanf_l "locale_t loc" "const char * restrict format" "..."
46.Ft int
47.Fn fscanf_l "FILE * restrict stream" "locale_t loc" "const char * restrict format" "..."
48.Ft int
49.Fn sscanf_l "const char * restrict str" "locale_t loc" "const char * restrict format" "..."
50.Ft int
51.Fn vfscanf_l "FILE * restrict stream" "locale_t loc" "const char * restrict format" "va_list ap"
52.Ft int
53.Fn vscanf_l "locale_t loc" "const char * restrict format" "va_list ap"
54.Ft int
55.Fn vsscanf_l "const char * restrict str" "locale_t loc" "const char * restrict format" "va_list ap"
56.Sh DESCRIPTION
57The above functions scan input according to a specified
58.Fa format
59in the locale
60.Fa loc .
61They behave in the same way as the versions without the _l suffix, but use
62the specific locale rather than the global or per-thread locale.
63See the specific manual pages for more information.
64.Sh SEE ALSO
65.Xr scanf 3 ,
66.Xr xlocale 3
67.Sh STANDARDS
68These functions do not conform to any specific standard so they should be
69considered as non-portable local extensions.
70.Sh HISTORY
71These functions first appeared in Darwin and were first implemented in
72.Fx 9.1
73and
74.Nx 7 .
75