Index: /trunk/psLib/test/pstap/src/pstap.h
===================================================================
--- /trunk/psLib/test/pstap/src/pstap.h	(revision 12383)
+++ /trunk/psLib/test/pstap/src/pstap.h	(revision 12384)
@@ -12,26 +12,30 @@
 # define checkMem() if(checkLeaks) mem()
 
-# ifdef __GNUC__
+// write a comment which is counted as a test (and swallowed by prove)
+# define note(...)\
+{ \
+    fprintf(stdout, __VA_ARGS__); \
+    fprintf(stdout, "\n[%s:%d in %s]\n", __FILE__, __LINE__, __func__); \
+}
 
-// write a comment which is counted as a test (and swallowed by prove)
-# define note(A, ...){ \
-fprintf(stdout, A, ## __VA_ARGS__); \
-fprintf(stdout, "\n[%s:%d in %s]\n", __FILE__, __LINE__, __func__); }
-// write a comment which is counted as a test (and swallowed by prove)
-# define noted(A, ...) _gen_result(1, __func__, __FILE__, __LINE__, A, ## __VA_ARGS__);
+# define noted(...) _gen_result(1, __func__, __FILE__, __LINE__, __VA_ARGS__);
 
 // use to test the value of a float
-# define ok_float(VALUE,EXPECT,COMMENT, ...)\
-ok((fabsf((VALUE)-(EXPECT)) < FLT_EPSILON), COMMENT, ## __VA_ARGS__);
+# define ok_float(VALUE, EXPECT, ...)\
+{ \
+    bool status = (fabsf(VALUE - EXPECT) < FLT_EPSILON); \
+    ok(status, __VA_ARGS__); \
+    if (!status) { \
+        diag("         got: '%f'", VALUE); \
+        diag("    expected: '%f'", EXPECT); \
+    } \
+}
 
-// use to test the value of a double
-# define ok_double(VALUE,EXPECT,COMMENT, ...)\
-ok((fabs((VALUE)-(EXPECT)) < DBL_EPSILON), COMMENT, ## __VA_ARGS__);
 
 // use to test the value of a float within a defined tolerance
-# define ok_float_tol(VALUE,EXPECT,TOL,COMMENT, ...)\
+# define ok_float_tol(VALUE,EXPECT,TOL,...)\
 { \
     bool status = (fabsf((VALUE) - (EXPECT)) < (TOL)); \
-    ok(status, COMMENT, ## __VA_ARGS__); \
+    ok(status, __VA_ARGS__); \
     if (!status) { \
         diag("         got: '%f'", VALUE); \
@@ -40,50 +44,14 @@
 }
 
-// use to test the value of a double within a defined tolerance
-# define ok_double_tol(VALUE,EXPECT,TOL,COMMENT, ...)\
+// use to test the value of a double
+# define ok_double(VALUE,EXPECT,...)\
 { \
-    bool status = (fabs((VALUE) - (EXPECT)) < (TOL)); \
-    ok(status, COMMENT, ## __VA_ARGS__); \
+    bool status = (fabs(VALUE - EXPECT) < DBL_EPSILON); \
+    ok(status, __VA_ARGS__); \
     if (!status) { \
         diag("         got: '%f'", VALUE); \
-        diag("    expected: '%f' +/- %f", EXPECT, TOL); \
+        diag("    expected: '%f'", EXPECT); \
     } \
 }
-
-# define ok_str(VALUE, EXPECT, COMMENT, ...) \
-{ \
-    int cmp = (strcmp(VALUE, EXPECT) == 0); \
-    ok(cmp, COMMENT, ## __VA_ARGS__); \
-    if (!cmp) { \
-        diag("         got: '%s'", VALUE); \
-        diag("    expected: '%s'", EXPECT); \
-    } \
-}
-
-# define ok_strn(VALUE, EXPECT, N, COMMENT, ...)\
-{ \
-    int cmp = (strncmp(VALUE, EXPECT, N) == 0); \
-    ok(cmp, COMMENT, ## __VA_ARGS__); \
-    if (!cmp) { \
-        diag("         got: '%s'", VALUE); \
-        diag("    expected: '%s'", EXPECT); \
-    } \
-}
-
-#elif __STDC_VERSION__ >= 199901L /* __GNUC__ */
-
-// write a comment which is counted as a test (and swallowed by prove)
-// write a comment which is counted as a test (and swallowed by prove)
-# define note(A, ...){ \
-    fprintf(stdout, A, ...); \
-    fprintf(stdout, "\n[%s:%d in %s]\n", __FILE__, __LINE__, __func__); }
-
-// use to test the value of a float
-# define ok_float(VALUE,EXPECT, ...)\
-ok((fabsf((VALUE)-(EXPECT)) < FLT_EPSILON), __VA_ARGS__);
-
-// use to test the value of a double
-# define ok_double(VALUE,EXPECT, ...)\
-ok((fabs((VALUE)-(EXPECT)) < DBL_EPSILON), __VA_ARGS__);
 
 // use to test the value of a float
@@ -112,5 +80,5 @@
 { \
     int cmp = (strcmp(VALUE, EXPECT) == 0); \
-    ok(cmp, COMMENT,  __VA_ARGS__); \
+    ok(cmp, __VA_ARGS__); \
     if (!cmp) { \
         diag("         got: '%s'", VALUE); \
@@ -122,5 +90,5 @@
 { \
     int cmp = (strncmp(VALUE, EXPECT, N) == 0); \
-    ok(cmp, COMMENT,  __VA_ARGS__); \
+    ok(cmp, __VA_ARGS__); \
     if (!cmp) { \
         diag("         got: '%s'", VALUE); \
@@ -129,5 +97,21 @@
 }
 
-#else /* __STDC_VERSION__ */
-# error "Needs gcc or C99 compiler for variadic macros."
-#endif /* __STDC_VERSION__ */
+# define is_int(VALUE, EXPECT, ...)\
+{ \
+    int cmp = (VALUE == EXPECT); \
+    ok(cmp, __VA_ARGS__); \
+    if (!cmp) { \
+        diag("         got: '%d'", VALUE); \
+        diag("    expected: '%d'", EXPECT); \
+    } \
+}
+
+# define is_long(VALUE, EXPECT, ...)\
+{ \
+    int cmp = (VALUE == EXPECT); \
+    ok(cmp, __VA_ARGS__); \
+    if (!cmp) { \
+        diag("         got: '%ld'", VALUE); \
+        diag("    expected: '%ld'", EXPECT); \
+    } \
+}
