From patchwork Sat Jun 17 08:42:02 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rical Jasan X-Patchwork-Id: 21062 Received: (qmail 110783 invoked by alias); 17 Jun 2017 08:42:08 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Delivered-To: mailing list libc-alpha@sourceware.org Received: (qmail 110740 invoked by uid 89); 17 Jun 2017 08:42:05 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-25.1 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, SPF_PASS, T_RP_MATCHES_RCVD autolearn=ham version=3.3.2 spammy=coming X-HELO: smtp.pacific.net From: Rical Jasan To: libc-alpha@sourceware.org Cc: Joseph Myers , Zack Weinberg , Carlos O'Donell , Michael Kerrisk Subject: manual: Refactor documentation of CHAR_BIT. Date: Sat, 17 Jun 2017 01:42:02 -0700 Message-Id: <20170617084202.4662-2-ricaljasan@pacific.net> In-Reply-To: <20170617084202.4662-1-ricaljasan@pacific.net> References: <20170617084202.4662-1-ricaljasan@pacific.net> MIME-Version: 1.0 This single-@item @table is better defined with @defvr, since the CHAR_BIT macro has @standards (being declared in a header), and @items in @tables are not considered annotatable. Using @defvr automatically includes the macro in the Variable and Constant Macro Index and ensures its inclusion the Summary of Library Facilities. The file include/limits.h identifies the macro as coming from C99. * manual/lang.texi (CHAR_BIT): Convert from an @table to an @defvr. Change standard from ISO to C99. --- manual/lang.texi | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/manual/lang.texi b/manual/lang.texi index cf0e4e73cd..4b04232e3c 100644 --- a/manual/lang.texi +++ b/manual/lang.texi @@ -629,9 +629,8 @@ There is no operator in the C language that can give you the number of bits in an integer data type. But you can compute it from the macro @code{CHAR_BIT}, defined in the header file @file{limits.h}. -@table @code -@item CHAR_BIT -@standards{ISO, limits.h} +@defvr Macro CHAR_BIT +@standards{C99, limits.h} This is the number of bits in a @code{char}---eight, on most systems. The value has type @code{int}. @@ -641,7 +640,7 @@ this: @smallexample sizeof (@var{type}) * CHAR_BIT @end smallexample -@end table +@end defvr That expression includes padding bits as well as value and sign bits. On all systems supported by @theglibc{}, standard integer types other