mirror of
https://github.com/freebsd/freebsd-src.git
synced 2026-10-28 11:25:21 +01:00
Fix compiler warnings related to the Fx macro, as well as all other mechanical typos that were visible within one screenful of them. These cause rendering glitches on various toolchains with various of the five and a half decades of rich output formats and tooling manpages scale to. The *x macro set specifies operating systems. These macros take the rest of the line as an argument. Sometimes, a space was not used to separate the argument of Fx and the trailing period. Another, FreeBSD Foundation was misrepresented as an operating system version instead of an author. Two more had other parts of the sentence supplied as an argument to Fx. While I had those open, fix the other mechancial typos visible on those specific screenfulls. Fix a list width glitch, correct section typo AUTHOR to AUTHORS, and switch AUTHORS sections containing prose to prose-mode so that they wrap freely when rendered. PR: 297248 MFC after: 3 days Fixes:d39e310c7d("man/man3: add stdbit.3") Fixes:d790b16bbf("add man pages for stdbit functions") Fixes:b61850c4e6("net.link.bridge.member_ifaddrs to false") Reported by: wosch (groff is complaining about incorrect Fx usage)
82 lines
1.6 KiB
Plaintext
82 lines
1.6 KiB
Plaintext
.\"
|
|
.\" Copyright (c) 2025 Robert Clausecker <[email protected]>
|
|
.\"
|
|
.\" SPDX-License-Identifier: BSD-2-Clause
|
|
.\"
|
|
.Dd November 9, 2025
|
|
.Dt STDC_BIT_CEIL 3
|
|
.Os
|
|
.Sh NAME
|
|
.Nm stdc_bit_ceil
|
|
.Nd round up to the next power of\~2
|
|
.Sh SYNOPSIS
|
|
.Lb libc
|
|
.In stdbit.h
|
|
.Ft unsigned char
|
|
.Fn stdc_bit_ceil_uc "unsigned char value"
|
|
.Ft unsigned short
|
|
.Fn stdc_bit_ceil_us "unsigned short value"
|
|
.Ft unsigned int
|
|
.Fn stdc_bit_ceil_ui "unsigned int value"
|
|
.Ft unsigned long
|
|
.Fn stdc_bit_ceil_ul "unsigned long value"
|
|
.Ft unsigned long long
|
|
.Fn stdc_bit_ceil_ull "unsigned long long value"
|
|
.Ft typeof Ns Pq Em value
|
|
.Fn stdc_bit_ceil "value"
|
|
.Sh DESCRIPTION
|
|
The
|
|
.Nm stdc_bit_ceil_ Ns Em type Ns ()
|
|
family of functions rounds
|
|
.Fa value
|
|
up to the next power of\~2, where
|
|
.Fa value
|
|
is of type
|
|
.Va unsigned char ,
|
|
.Va unsigned short ,
|
|
.Va unsigned int ,
|
|
.Va unsigned long ,
|
|
or
|
|
.Va unsigned long long
|
|
for
|
|
.Em type
|
|
being
|
|
.Sy uc ,
|
|
.Sy us ,
|
|
.Sy ui ,
|
|
.Sy ul ,
|
|
or
|
|
.Sy ull
|
|
respectively.
|
|
The
|
|
.Fn stdc_bit_ceil "value"
|
|
type-generic macro picks the appropriate
|
|
.Nm stdc_bit_ceil_ Ns Em type Ns ()
|
|
function based on the type of
|
|
.Fa value .
|
|
.Sh RETURN VALUES
|
|
Returns
|
|
.Fa value
|
|
round up to the next power of\~2.
|
|
If this value is not representable,
|
|
0\~is returned.
|
|
.Sh SEE ALSO
|
|
.Xr stdbit 3 ,
|
|
.Xr stdc_bit_floor 3
|
|
.Sh STANDARDS
|
|
The
|
|
.Nm stdc_bit_ceil_ Ns Em type Ns ()
|
|
family of functions and the
|
|
.Fn stdc_bit_ceil
|
|
type-generic macro conform to
|
|
.St -isoC-2023 .
|
|
.Sh HISTORY
|
|
The
|
|
.Nm stdc_bit_ceil_ Ns Em type Ns ()
|
|
family of functions and the
|
|
.Fn stdc_bit_ceil
|
|
type-generic macro were added in
|
|
.Fx 15.1 .
|
|
.Sh AUTHORS
|
|
.An Robert Clausecker Aq Mt [email protected]
|