test: 90-abtod: Remove printf dependency. Fixes gcc.
authorJan Nieuwenhuizen <janneke@gnu.org>
Mon, 2 Dec 2019 09:00:03 +0000 (10:00 +0100)
committerJan Nieuwenhuizen <janneke@gnu.org>
Mon, 2 Dec 2019 09:00:03 +0000 (10:00 +0100)
* lib/tests/mes/90-abtod.stdout: Remove.
* lib/tests/mes/90-abtod.c (main): Remove printf.

build-aux/check-mescc.sh
lib/tests/mes/90-abtod.c
lib/tests/mes/90-abtod.stdout [deleted file]

index f060da67f0684539644c3b2336d30e773f8ae380..8abd9d7acd82c2a7c7c8c46bfc9ecf409045982c 100755 (executable)
@@ -226,7 +226,6 @@ lib/tests/scaffold/a1-global-no-clobber.c
 fi
 
 XFAIL_TESTS="
 fi
 
 XFAIL_TESTS="
-lib/tests/mes/90-abtod.c
 lib/tests/stdio/90-sprintf.c
 "
 
 lib/tests/stdio/90-sprintf.c
 "
 
@@ -236,6 +235,7 @@ lib/tests/scaffold/17-compare-unsigned-char-le.c
 lib/tests/scaffold/17-compare-unsigned-short-le.c
 lib/tests/scaffold/66-local-char-array.c
 lib/tests/scaffold/72-typedef-struct-def-local.c
 lib/tests/scaffold/17-compare-unsigned-short-le.c
 lib/tests/scaffold/66-local-char-array.c
 lib/tests/scaffold/72-typedef-struct-def-local.c
+lib/tests/mes/90-abtod.c
 lib/tests/mes/90-dtoab.c
 lib/tests/scaffold/90-goto-var.c
 lib/tests/scaffold/91-goto-array.c
 lib/tests/mes/90-dtoab.c
 lib/tests/scaffold/90-goto-var.c
 lib/tests/scaffold/91-goto-array.c
@@ -261,7 +261,6 @@ fi
 
 if test $compiler = gcc; then
     XFAIL_TESTS="$XFAIL_TESTS
 
 if test $compiler = gcc; then
     XFAIL_TESTS="$XFAIL_TESTS
-lib/tests/mes/90-abtod.c
 "
 
     if test $mes_cpu = x86; then
 "
 
     if test $mes_cpu = x86; then
@@ -277,7 +276,6 @@ lib/tests/stdio/70-printf-simple.c
 lib/tests/stdio/70-printf.c
 lib/tests/scaffold/70-extern.c
 lib/tests/stdio/80-sscanf.c
 lib/tests/stdio/70-printf.c
 lib/tests/scaffold/70-extern.c
 lib/tests/stdio/80-sscanf.c
-lib/tests/mes/90-abtod.c
 lib/tests/posix/90-execlp.c
 lib/tests/string/90-snprintf.c
 "
 lib/tests/posix/90-execlp.c
 lib/tests/string/90-snprintf.c
 "
index 98d7d58a9ec481642f9c2c36f5a39fea0dde55ad..b88bb7463474fbc508662c57e449a5853e5a63e8 100644 (file)
@@ -26,9 +26,10 @@ int
 main ()
 {
   char *s = "1.2e3";
 main ()
 {
   char *s = "1.2e3";
-  char *p = s;
+  char const *p = s;
   double d = abtod (&p, 0);
   double d = abtod (&p, 0);
-  printf ("%f\n", d);
+  if (d != 1200)
+    return d;
 
   return 0;
 }
 
   return 0;
 }
diff --git a/lib/tests/mes/90-abtod.stdout b/lib/tests/mes/90-abtod.stdout
deleted file mode 100644 (file)
index 84402f4..0000000
+++ /dev/null
@@ -1 +0,0 @@
-1200.000000