aboutsummaryrefslogtreecommitdiffstats
path: root/man3/libsimple_strtou.3
diff options
context:
space:
mode:
authorMattias Andrée <maandree@kth.se>2024-08-18 09:58:23 +0200
committerMattias Andrée <maandree@kth.se>2024-08-18 09:58:23 +0200
commita69f0f613687edf6c1f1ee83b462f77e8ea3c9a9 (patch)
treed976683461a0f427d2f1ef79a8732a048dd0c67b /man3/libsimple_strtou.3
parentMerge tag '1.3' into since (diff)
parentUpdate VERSION_MINOR (diff)
downloadlibsimple-a69f0f613687edf6c1f1ee83b462f77e8ea3c9a9.tar.gz
libsimple-a69f0f613687edf6c1f1ee83b462f77e8ea3c9a9.tar.bz2
libsimple-a69f0f613687edf6c1f1ee83b462f77e8ea3c9a9.tar.xz
Merge tag '1.4' into since
Version 1.4
Diffstat (limited to '')
-rw-r--r--man3/libsimple_strtou.3202
1 files changed, 202 insertions, 0 deletions
diff --git a/man3/libsimple_strtou.3 b/man3/libsimple_strtou.3
new file mode 100644
index 0000000..4e4bb33
--- /dev/null
+++ b/man3/libsimple_strtou.3
@@ -0,0 +1,202 @@
+.TH LIBSIMPLE_STRTOU 3 libsimple
+.SH NAME
+libsimple_strto{u,uh,uhh,uz,u8,u16,u32,u64} \- parse a string as an unsigned integer
+
+.SH SYNOPSIS
+.nf
+#include <libsimple.h>
+
+unsigned int libsimple_strtou(const char *\fInptr\fP, char **\fIend\fP, int \fIbase\fP);
+unsigned short int libsimple_strtouh(const char *\fInptr\fP, char **\fIend\fP, int \fIbase\fP);
+unsigned char libsimple_strtouhh(const char *\fInptr\fP, char **\fIend\fP, int \fIbase\fP);
+inline size_t libsimple_strtouz(const char *\fInptr\fP, char **\fIend\fP, int \fIbase\fP);
+uint_least8_t libsimple_strtou8(const char *\fInptr\fP, char **\fIend\fP, int \fIbase\fP);
+uint_least16_t libsimple_strtou16(const char *\fInptr\fP, char **\fIend\fP, int \fIbase\fP);
+uint_least32_t libsimple_strtou32(const char *\fInptr\fP, char **\fIend\fP, int \fIbase\fP);
+uint_least64_t libsimple_strtou64(const char *\fInptr\fP, char **\fIend\fP, int \fIbase\fP);
+
+#ifndef strtou
+# define strtou libsimple_strtou
+#endif
+#ifndef strtouh
+# define strtouh libsimple_strtouh
+#endif
+#ifndef strtouhh
+# define strtouhh libsimple_strtouhh
+#endif
+#ifndef strtouz
+# define strtouz libsimple_strtouz
+#endif
+#ifndef strtou8
+# define strtou8 libsimple_strtou8
+#endif
+#ifndef strtou16
+# define strtou16 libsimple_strtou16
+#endif
+#ifndef strtou32
+# define strtou32 libsimple_strtou32
+#endif
+#ifndef strtou64
+# define strtou64 libsimple_strtou64
+#endif
+.fi
+.PP
+Link with
+.IR \-lsimple .
+
+.SH DESCRIPTION
+The
+.BR libsimple_strtou ()
+function is a version of the
+.BR strtoul (3)
+function, that returns au
+.BR "unsigned int" .
+.PP
+The
+.BR libsimple_strtouh ()
+function is a version of the
+.BR strtoul (3)
+function, that returns au
+.BR "unsigned short int" .
+.PP
+The
+.BR libsimple_strtouhh ()
+function is a version of the
+.BR strtoul (3)
+function, that returns au
+.BR "unsigned char" .
+.PP
+The
+.BR libsimple_strtouz ()
+function is a version of the
+.BR strtoul (3)
+function, that returns a
+.BR size_t .
+.PP
+The
+.BR libsimple_strtou8 ()
+function is a version of the
+.BR strtoul (3)
+function, that returns a
+.B uint_least8_t
+restricted to the range of
+.BR uint8_t .
+.PP
+The
+.BR libsimple_strtou16 ()
+function is a version of the
+.BR strtoul (3)
+function, that returns a
+.B uint_least16_t
+restricted to the range of
+.BR uint16_t .
+.PP
+The
+.BR libsimple_strtou32 ()
+function is a version of the
+.BR strtoul (3)
+function, that returns a
+.B uint_least32_t
+restricted to the range of
+.BR uint32_t .
+.PP
+The
+.BR libsimple_strtou64 ()
+function is a version of the
+.BR strtoul (3)
+function, that returns a
+.B uint_least64_t
+restricted to the range of
+.BR uint64_t .
+
+.SH RETURN VALUE
+See
+.BR strtoul (3).
+
+.SH ERRORS
+See
+.BR strtoul (3).
+
+.SH ATTRIBUTES
+For an explanation of the terms used in this section, see
+.BR attributes (7).
+.TS
+allbox;
+lb lb lb
+l l l.
+Interface Attribute Value
+T{
+.BR libsimple_strtou (),
+.br
+.BR libsimple_strtouh (),
+.br
+.BR libsimple_strtouhh (),
+.br
+.BR libsimple_strtouz (),
+.br
+.BR libsimple_strtou8 (),
+.br
+.BR libsimple_strtou16 (),
+.br
+.BR libsimple_strtou32 (),
+.br
+.BR libsimple_strtou64 ()
+T} Thread safety MT-Safe
+T{
+.BR libsimple_strtou (),
+.br
+.BR libsimple_strtouh (),
+.br
+.BR libsimple_strtouhh (),
+.br
+.BR libsimple_strtouz (),
+.br
+.BR libsimple_strtou8 (),
+.br
+.BR libsimple_strtou16 (),
+.br
+.BR libsimple_strtou32 (),
+.br
+.BR libsimple_strtou64 ()
+T} Async-signal safety AS-Safe
+T{
+.BR libsimple_strtou (),
+.br
+.BR libsimple_strtouh (),
+.br
+.BR libsimple_strtouhh (),
+.br
+.BR libsimple_strtouz (),
+.br
+.BR libsimple_strtou8 (),
+.br
+.BR libsimple_strtou16 (),
+.br
+.BR libsimple_strtou32 (),
+.br
+.BR libsimple_strtou64 ()
+T} Async-cancel safety AC-Safe
+.TE
+
+.SH EXAMPLES
+None.
+
+.SH APPLICATION USAGE
+None.
+
+.SH RATIONALE
+None.
+
+.SH FUTURE DIRECTIONS
+None.
+
+.SH NOTES
+None.
+
+.SH BUGS
+None.
+
+.SH SEE ALSO
+.BR libsimple_strtoi (3),
+.BR strtoul (3),
+.BR strtoull (3)