bug-bison
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [GNU Bison 2.5.1] testsuite: 215 216 218 219 221 222 failed


From: Akim Demaille
Subject: Re: [GNU Bison 2.5.1] testsuite: 215 216 218 219 221 222 failed
Date: Fri, 5 Oct 2012 08:58:29 +0200

Le 4 oct. 2012 à 23:14, Didier Godefroy a écrit :

> Existing Grammars.
> 
> 215: GNU AWK 3.1.0 Grammar: LALR(1)                  FAILED (existing.at:76)
> 216: GNU AWK 3.1.0 Grammar: IELR(1)                  FAILED (existing.at:76)
> 217: GNU AWK 3.1.0 Grammar: Canonical LR(1)          ok
> 218: GNU Cim Grammar: LALR(1)                        FAILED (existing.at:780)
> 219: GNU Cim Grammar: IELR(1)                        FAILED (existing.at:780)
> 220: GNU Cim Grammar: Canonical LR(1)                ok
> 221: GNU pic (Groff 1.18.1) Grammar: LALR(1)         FAILED (existing.at:1400)
> 222: GNU pic (Groff 1.18.1) Grammar: IELR(1)         FAILED (existing.at:1400)
> 223: GNU pic (Groff 1.18.1) Grammar: Canonical LR(1) ok

Hi!

Well, it seems that your diff does not support -u:

215. existing.at:76: testing GNU AWK 3.1.0 Grammar: LALR(1) ...
./existing.at:76: bison --report=all --defines -o input.c input.y
./existing.at:76: sed -n 's/^state //p' input.output | tail -1
./existing.at:76: sed 's/^%define lr.type .*$//' input.y > input-lalr.y
./existing.at:76: bison --report=all input-lalr.y
stderr:
input-lalr.y: conflicts: 65 shift/reduce
stdout:
./existing.at:76: diff -u input-lalr.output input.output \
           | sed -n '/^@@/,$p' | sed 's/^ $//'
0a1,3
> diff: illegal option -- u
> Usage: diff [-bitw] [-c |-C Lines|-D String|-e|-f|-h|-n] File1 File2
>        diff [-bilrstw] [-c |-C Lines|-e|-f|-h|-n] [-S File] Directory1 
> Directory2
215. existing.at:76: 215. GNU AWK 3.1.0 Grammar: LALR(1) (existing.at:76): 
FAILED (existing.at:76)

Autoconf's manual confirms this:

`diff'
     Option `-u' is nonportable.

     Some implementations, such as Tru64's, fail when comparing to
     `/dev/null'.  Use an empty file instead.

But it's also Tru that's its been a while since I last read this:

hostname = orbhost.orbhost.net
uname -m = alpha
uname -r = V5.1
uname -s = OSF1
uname -v = 2650

:)

I installed this:

commit a1a77e1fcc32e94aff477f2a98c15172b199d1e0
Author: Akim Demaille <address@hidden>
Date:   Fri Oct 5 08:54:15 2012 +0200

    tests: diff -u is not portable
    
    Reported by Didier Godefroy
    <http://lists.gnu.org/archive/html/bug-bison/2012-10/msg00006.html>.
    
    * tests/existing.at (AT_LALR1_DIFF_CHECK): Skip if diff -u does not
    work.

diff --git a/NEWS b/NEWS
index c1ab7aa..c8a4d31 100644
--- a/NEWS
+++ b/NEWS
@@ -4,7 +4,7 @@ GNU Bison NEWS
 
 ** Bug fixes
 
-  Bugs in the test suite have been fixed.
+  Bugs and portability issues in the test suite have been fixed.
 
   Some errors in translations have been addressed, and --help now directs
   users to the appropriate place to report them.
diff --git a/tests/existing.at b/tests/existing.at
index 582f6b3..149499d 100644
--- a/tests/existing.at
+++ b/tests/existing.at
@@ -35,7 +35,10 @@ dnl time comes, just use sed to drop the line numbers.  For 
now, as LR(1)
 dnl support is rapidly evolving, let's keep that information to be careful.
 dnl However, we don't do diffs for canonical LR(1) because the diff is huge.
 m4_pushdef([AT_LALR1_DIFF_CHECK],
-[AT_CHECK([[sed 's/^%define lr.type .*$//' input.y > input-lalr.y]])
+[dnl We need diff -u, which is not portable.
+AT_CHECK([diff -u /dev/null /dev/null || exit 77], [0], [ignore])
+
+AT_CHECK([[sed 's/^%define lr.type .*$//' input.y > input-lalr.y]])
 AT_BISON_CHECK([[--report=all input-lalr.y]], [[0]], [ignore], [ignore])
 AT_CHECK([[diff -u input-lalr.output input.output \
            | sed -n '/^@@/,$p' | sed 's/^ $//']],





reply via email to

[Prev in Thread] Current Thread [Next in Thread]