RSeries astromech firmware
FormatString.h File Reference
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define FL_LEFTADJUST   0x0001U
 
#define FL_SIGN   0x0002U
 
#define FL_ZEROPAD   0x0004U
 
#define FL_ALTERNATE   0x0008U
 
#define FL_SPACE   0x0010U
 
#define FL_SHORT   0x0020U
 
#define FL_LONG   0x0040U
 
#define FL_LONGDOUBLE   0x0080U
 
#define FL_POINTER   0x0100U
 
#define MAX_WIDTH   ((SHRT_MAX - 9) / 10)
 
#define DBL_DIG   15
 
#define BUFFER_LEN   1000
 
#define PUTSTR(szPutStr, iPutLen)
 
#define PAD(szPadStr, iPadLen)
 
#define PADSPACES(iPadWidth)   PAD(szSpaces, iPadWidth)
 
#define PADZEROS(iPadWidth)   PAD(szZeros, iPadWidth)
 
#define iIsBigEndian()   (*(char*)&iEndianChk == 0)
 
#define iIsNanOrInf(puVal)
 

Functions

int FormatString (char **acBuf, const char *szFmt, va_list tArg)
 

Macro Definition Documentation

◆ BUFFER_LEN

#define BUFFER_LEN   1000

◆ DBL_DIG

#define DBL_DIG   15

◆ FL_ALTERNATE

#define FL_ALTERNATE   0x0008U

◆ FL_LEFTADJUST

#define FL_LEFTADJUST   0x0001U

◆ FL_LONG

#define FL_LONG   0x0040U

◆ FL_LONGDOUBLE

#define FL_LONGDOUBLE   0x0080U

◆ FL_POINTER

#define FL_POINTER   0x0100U

◆ FL_SHORT

#define FL_SHORT   0x0020U

◆ FL_SIGN

#define FL_SIGN   0x0002U

◆ FL_SPACE

#define FL_SPACE   0x0010U

◆ FL_ZEROPAD

#define FL_ZEROPAD   0x0004U

◆ iIsBigEndian

#define iIsBigEndian ( )    (*(char*)&iEndianChk == 0)

◆ iIsNanOrInf

#define iIsNanOrInf (   puVal)

◆ MAX_WIDTH

#define MAX_WIDTH   ((SHRT_MAX - 9) / 10)

◆ PAD

#define PAD (   szPadStr,
  iPadLen 
)
Value:
{ \
if (iPadLen > 0) \
{ \
iTmp = iPadLen; \
while (iTmp >= 32) \
{ \
if (iOutFoo(pvOutData, (const char*)szPadStr, 32) < 0) \
return -1; \
iOutCount += 32; \
iTmp -= 32; \
} \
if (iTmp) \
{ \
if (iOutFoo(pvOutData, (const char*)szPadStr, (size_t)iTmp) < 0) \
return -1; \
iOutCount += iTmp; \
} \
} \
}

◆ PADSPACES

#define PADSPACES (   iPadWidth)    PAD(szSpaces, iPadWidth)

◆ PADZEROS

#define PADZEROS (   iPadWidth)    PAD(szZeros, iPadWidth)

◆ PUTSTR

#define PUTSTR (   szPutStr,
  iPutLen 
)
Value:
{ \
if (iPutLen > 0) \
if (iOutFoo(pvOutData, (const char*)szPutStr, (size_t)iPutLen) < 0) \
return -1; \
iOutCount += iPutLen; \
}

Function Documentation

◆ FormatString()

int FormatString ( char **  acBuf,
const char *  szFmt,
va_list  tArg 
)