int_fmtio.h (7c478bd9) | int_fmtio.h (ba3594ba) |
---|---|
1/* 2 * CDDL HEADER START 3 * 4 * The contents of this file are subject to the terms of the 5 * Common Development and Distribution License, Version 1.0 only 6 * (the "License"). You may not use this file except in compliance 7 * with the License. 8 * --- 6 unchanged lines hidden (view full) --- 15 * file and include the License file at usr/src/OPENSOLARIS.LICENSE. 16 * If applicable, add the following below this CDDL HEADER, with the 17 * fields enclosed by brackets "[]" replaced with your own identifying 18 * information: Portions Copyright [yyyy] [name of copyright owner] 19 * 20 * CDDL HEADER END 21 */ 22/* | 1/* 2 * CDDL HEADER START 3 * 4 * The contents of this file are subject to the terms of the 5 * Common Development and Distribution License, Version 1.0 only 6 * (the "License"). You may not use this file except in compliance 7 * with the License. 8 * --- 6 unchanged lines hidden (view full) --- 15 * file and include the License file at usr/src/OPENSOLARIS.LICENSE. 16 * If applicable, add the following below this CDDL HEADER, with the 17 * fields enclosed by brackets "[]" replaced with your own identifying 18 * information: Portions Copyright [yyyy] [name of copyright owner] 19 * 20 * CDDL HEADER END 21 */ 22/* |
23 * Copyright 2014 Garrett D'Amore <garrett@damore.org> 24 * |
|
23 * Copyright 2004 Sun Microsystems, Inc. All rights reserved. 24 * Use is subject to license terms. 25 */ 26 27#ifndef _SYS_INT_FMTIO_H 28#define _SYS_INT_FMTIO_H 29 | 25 * Copyright 2004 Sun Microsystems, Inc. All rights reserved. 26 * Use is subject to license terms. 27 */ 28 29#ifndef _SYS_INT_FMTIO_H 30#define _SYS_INT_FMTIO_H 31 |
30#pragma ident "%Z%%M% %I% %E% SMI" 31 | |
32/* 33 * This file, <sys/int_fmtio.h>, is part of the Sun Microsystems implementation 34 * of <inttypes.h> as defined by the ISO C Standard, ISO/IEC 9899:1999 35 * Programming language - C. 36 * 37 * ISO International Organization for Standardization. 38 * 39 * Programs/Modules should not directly include this file. Access to the --- 49 unchanged lines hidden (view full) --- 89 90#define _PRId "d" 91#define _PRIi "i" 92#define _PRIo "o" 93#define _PRIu "u" 94#define _PRIx "x" 95#define _PRIX "X" 96 | 32/* 33 * This file, <sys/int_fmtio.h>, is part of the Sun Microsystems implementation 34 * of <inttypes.h> as defined by the ISO C Standard, ISO/IEC 9899:1999 35 * Programming language - C. 36 * 37 * ISO International Organization for Standardization. 38 * 39 * Programs/Modules should not directly include this file. Access to the --- 49 unchanged lines hidden (view full) --- 89 90#define _PRId "d" 91#define _PRIi "i" 92#define _PRIo "o" 93#define _PRIu "u" 94#define _PRIx "x" 95#define _PRIX "X" 96 |
97#if defined(_CHAR_IS_SIGNED) || defined(__STDC__) | |
98#define PRId8 _MODF8 _PRId 99#define PRIdLEAST8 PRId8 100#define PRIdFAST8 PRId8 | 97#define PRId8 _MODF8 _PRId 98#define PRIdLEAST8 PRId8 99#define PRIdFAST8 PRId8 |
101#endif | |
102#define PRId16 _MODF16 _PRId 103#define PRIdLEAST16 PRId16 104#define PRId32 "d" 105#define PRIdFAST16 PRId32 106#define PRIdLEAST32 PRId32 107#define PRIdFAST32 PRId32 108#ifdef _LP64 109#define PRId64 "ld" 110#else /* _ILP32 */ 111#if defined(_LONGLONG_TYPE) 112#define PRId64 "lld" 113#endif 114#endif 115#ifdef PRId64 116#define PRIdLEAST64 PRId64 117#define PRIdFAST64 PRId64 118#endif 119 | 100#define PRId16 _MODF16 _PRId 101#define PRIdLEAST16 PRId16 102#define PRId32 "d" 103#define PRIdFAST16 PRId32 104#define PRIdLEAST32 PRId32 105#define PRIdFAST32 PRId32 106#ifdef _LP64 107#define PRId64 "ld" 108#else /* _ILP32 */ 109#if defined(_LONGLONG_TYPE) 110#define PRId64 "lld" 111#endif 112#endif 113#ifdef PRId64 114#define PRIdLEAST64 PRId64 115#define PRIdFAST64 PRId64 116#endif 117 |
120#if defined(_CHAR_IS_SIGNED) || defined(__STDC__) | |
121#define PRIi8 _MODF8 _PRIi 122#define PRIiLEAST8 PRIi8 123#define PRIiFAST8 PRIi8 | 118#define PRIi8 _MODF8 _PRIi 119#define PRIiLEAST8 PRIi8 120#define PRIiFAST8 PRIi8 |
124#endif | |
125#define PRIi16 _MODF16 _PRIi 126#define PRIiLEAST16 PRIi16 127#define PRIi32 "i" 128#define PRIiFAST16 PRIi32 129#define PRIiLEAST32 PRIi32 130#define PRIiFAST32 PRIi32 131#ifdef _LP64 132#define PRIi64 "li" --- 113 unchanged lines hidden (view full) --- 246#define PRIuPTR "u" 247#define PRIxPTR "x" 248#define PRIXPTR "X" 249#endif /* defined(_LP64) || defined(_I32LPx) */ 250 251/* 252 * fscanf macros for signed integers 253 */ | 121#define PRIi16 _MODF16 _PRIi 122#define PRIiLEAST16 PRIi16 123#define PRIi32 "i" 124#define PRIiFAST16 PRIi32 125#define PRIiLEAST32 PRIi32 126#define PRIiFAST32 PRIi32 127#ifdef _LP64 128#define PRIi64 "li" --- 113 unchanged lines hidden (view full) --- 242#define PRIuPTR "u" 243#define PRIxPTR "x" 244#define PRIXPTR "X" 245#endif /* defined(_LP64) || defined(_I32LPx) */ 246 247/* 248 * fscanf macros for signed integers 249 */ |
254#if defined(_CHAR_IS_SIGNED) || defined(__STDC__) | |
255#define SCNd8 "hhd" 256#define SCNdLEAST8 SCNd8 257#define SCNdFAST8 SCNd8 | 250#define SCNd8 "hhd" 251#define SCNdLEAST8 SCNd8 252#define SCNdFAST8 SCNd8 |
258#endif | |
259#define SCNd16 "hd" 260#define SCNdLEAST16 SCNd16 261#define SCNd32 "d" 262#define SCNdFAST16 SCNd32 263#define SCNdLEAST32 SCNd32 264#define SCNdFAST32 SCNd32 265#ifdef PRId64 266#define SCNd64 PRId64 267#define SCNdLEAST64 PRId64 268#define SCNdFAST64 PRId64 269#endif 270#define SCNdPTR PRIdPTR 271 | 253#define SCNd16 "hd" 254#define SCNdLEAST16 SCNd16 255#define SCNd32 "d" 256#define SCNdFAST16 SCNd32 257#define SCNdLEAST32 SCNd32 258#define SCNdFAST32 SCNd32 259#ifdef PRId64 260#define SCNd64 PRId64 261#define SCNdLEAST64 PRId64 262#define SCNdFAST64 PRId64 263#endif 264#define SCNdPTR PRIdPTR 265 |
272#if defined(_CHAR_IS_SIGNED) || defined(__STDC__) | |
273#define SCNi8 "hhi" 274#define SCNiLEAST8 SCNi8 275#define SCNiFAST8 SCNi8 | 266#define SCNi8 "hhi" 267#define SCNiLEAST8 SCNi8 268#define SCNiFAST8 SCNi8 |
276#endif | |
277#define SCNi16 "hi" 278#define SCNiLEAST16 SCNi16 279#define SCNi32 "i" 280#define SCNiFAST16 SCNi32 281#define SCNiLEAST32 SCNi32 282#define SCNiFAST32 SCNi32 283#ifdef PRIi64 284#define SCNi64 PRIi64 --- 103 unchanged lines hidden --- | 269#define SCNi16 "hi" 270#define SCNiLEAST16 SCNi16 271#define SCNi32 "i" 272#define SCNiFAST16 SCNi32 273#define SCNiLEAST32 SCNi32 274#define SCNiFAST32 SCNi32 275#ifdef PRIi64 276#define SCNi64 PRIi64 --- 103 unchanged lines hidden --- |