]> pd.if.org Git - pdclib/blobdiff - functions/_PDCLIB/print.c
* Test cleanups: surround the code for all functions by #ifndef REGTEST
[pdclib] / functions / _PDCLIB / print.c
index 72db66bed2590a275e9bb346a1bc5a06ff2c55e5..124496c4cc1e1b43a943a2dc399df7dd1c49ad5a 100644 (file)
@@ -12,6 +12,8 @@
 #include <stdlib.h>
 #include <stddef.h>
 
+#ifndef REGTEST
+
 /* Using an integer's bits as flags for both the conversion flags and length
    modifiers.
 */
@@ -506,12 +508,15 @@ const char * _PDCLIB_print( const char * spec, struct _PDCLIB_status_t * status
     return ++spec;
 }
 
+#endif
+
 #ifdef TEST
 #define _PDCLIB_FILEID "_PDCLIB/print.c"
 #define _PDCLIB_STRINGIO
 
 #include <_PDCLIB_test.h>
 
+#ifndef REGTEST
 static int testprintf( char * buffer, const char * format, ... )
 {
     /* Members: base, flags, n, i, current, s, width, prec, stream, arg      */
@@ -535,13 +540,16 @@ static int testprintf( char * buffer, const char * format, ... )
     va_end( status.arg );
     return status.i;
 }
+#endif
 
 #define TEST_CONVERSION_ONLY
 
 int main( void )
 {
+#ifndef REGTEST
     char target[100];
 #include "printf_testcases.h"
+#endif
     return TEST_RESULTS;
 }