Open System Services System Calls Reference Manual (G06.28+, H06.05+)

System Functions (s and S) spt_printfx(2)
S Accepts a pointer to an array of wchar_t type. Wide characters from the
array are converted to an array of bytes containing multibyte characters
and the multibyte characters up to (but not including) the null character
are printed. If a precision is specied, no more than the number of bytes
specied by the precision are printed. If the precision is not specied or
is greater than the size of the array of bytes, the array of wide characters
must be terminated by a null wide character. If a minimum eld width is
specied and the array of bytes occupy fewer bytes than the specied
width, the array is padded with space characters to the specied width.
p Accepts a pointer to void. The value of the pointer is converted to a
sequence of printable characters, the same as unsigned hexadecimal
integer (x).
n Accepts a pointer to an integer into which is written the number of char-
acters written to the output stream so far by this call. No argument is
converted.
If the result of a conversion is wider than the eld width, the eld is expanded to contain the con-
verted result. No truncation occurs. However, a small precision can cause truncation on the
right.
The e, E, f, and g formats represent the special oating-point values as follows:
Quiet NaN NaN
Signaling NaN NaN
+/-INF +Inf or -Inf
+/-0 +0.0 or -0.0 (zero)
The representation of the + (plus sign) depends on whether the + or (space) formatting ag is
specied.
The spt_printfx( ) function allows for the insertion of a language-dependent radix character in
the output string. The radix character is dened by langinfo data in the programs locale
(category LC_NUMERIC). In the C locale, or in a locale where the radix character is not
dened, the radix character defaults to . (period).
The st_ctime and st_mtime elds of the le are marked for update between the successful exe-
cution of the spt_printfx() function and the next successful completion of a call to the
spt_fushx( ) or spt_fclosex() functions on the same stream, or a call to the exit() or abort()
functions.
NOTES
The macro to map printf() to spt_printfx() is available in C applications when
SPT_THREAD_AWARE_NONBLOCK has been dened in the following manner before
including spthread.h:
#dene SPT_THREAD_AWARE_NONBLOCK
The alias to link printf() to spt_printfx() is available in C++ applications when
SPT_THREAD_AWARE_PRAGMA_NONBLOCK has been dened in the following manner
before including spthread.h:
#dene SPT_THREAD_AWARE_PRAGMA_NONBLOCK
This function supports both IEEE Std 754-1985 oating-point and Tandem oating-point values
in the native environment. IEEE values can include NaN and innity, and the sign of 0.0 (zero)
527186-007 Hewlett-Packard Company 7217