aboutsummaryrefslogtreecommitdiff
path: root/tests/cxx/parser/built-in/driver.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'tests/cxx/parser/built-in/driver.cxx')
-rw-r--r--tests/cxx/parser/built-in/driver.cxx26
1 files changed, 26 insertions, 0 deletions
diff --git a/tests/cxx/parser/built-in/driver.cxx b/tests/cxx/parser/built-in/driver.cxx
index adaea5a..99c2f63 100644
--- a/tests/cxx/parser/built-in/driver.cxx
+++ b/tests/cxx/parser/built-in/driver.cxx
@@ -6,7 +6,9 @@
// Test built-in type parsing.
//
+#include <string.h> // strlen, strcmp
#include <string>
+#include <fstream>
#include <iostream>
#include "test-pskel.hxx"
@@ -542,6 +544,30 @@ main (int argc, char* argv[])
return 1;
}
+ // Ignore one of the tests depending on whether long long is available.
+ //
+ {
+ char* s = argv[1];
+ size_t n = strlen (s);
+
+ if (strcmp (s + n - 12,
+#ifdef XSDE_LONGLONG
+ "test-000.xml"
+#else
+ "test-001.xml"
+#endif
+ ) == 0)
+ {
+ s[n - 3] = 's';
+ s[n - 2] = 't';
+ s[n - 1] = 'd';
+
+ ifstream ifs (s);
+ cout << ifs.rdbuf ();
+ return 0;
+ }
+ }
+
try
{
any_type_pimpl any_type_p;