This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Committed: do not use [:digit:] et al in testsuite (was: Re: FAIL: elf section5 list, cris-axis-elf)
- From: Hans-Peter Nilsson <hans-peter dot nilsson at axis dot com>
- To: binutils at sources dot redhat dot com
- Date: Tue, 21 Dec 2004 14:12:23 +0100
- Subject: Committed: do not use [:digit:] et al in testsuite (was: Re: FAIL: elf section5 list, cris-axis-elf)
> Date: Thu, 16 Dec 2004 16:43:53 +0100
> From: Hans-Peter Nilsson <hp@axis.com>
> So, the [:digit:] is valid in newish tcl?
To answer this myself, apparently the construct was introduced
between Tcl 8.0 and Tcl 8.2.3, from looking at the manuals at
<URL:http://tcl.tk/>. Because the tcl requirement from dejagnu
(from looking at the RPM spec of 1.4.2) is just Tcl 8.0, later
constructs should not be used.
> In absence of a
> mandated dejagnu (+tcl+expect) version, I think it's not
> appropriate to use constructs only covered in new tcl versions
> and will commit a change to instead use [0-9] as obvious soonish
> unless someone else fixes it first.
Committed as below.
gas/testsuite:
* gas/elf/section5.e, gas/elf/section5.l: Replace [:digit:],
[:xdigit:] and {N} in regexps with [0-9], [0-9a-fA-F] and N
copies, to cater to tcl versions before Tcl 8.2.3.
Index: section5.e
===================================================================
RCS file: /cvs/src/src/gas/testsuite/gas/elf/section5.e,v
retrieving revision 1.1
diff -c -p -r1.1 section5.e
*** section5.e 16 Dec 2004 13:23:22 -0000 1.1
--- section5.e 21 Dec 2004 05:24:06 -0000
***************
*** 1,8 ****
! .* \.test0[ ]+PROGBITS[ ]+([[:xdigit:]]+[ ]+){4}[ ]+[[:digit:]]+.*
! .* \.test1[ ]+PROGBITS[ ]+([[:xdigit:]]+[ ]+){4}[ ]+[[:digit:]]+.*
.* \.rela?\.test1[ ]+RELA?[ ]+.*
! .* \.test2[ ]+PROGBITS[ ]+([[:xdigit:]]+[ ]+){4}[ ]+[[:digit:]]+.*
.* \.rela?\.test2[ ]+RELA?[ ]+.*
! .* \.test3[ ]+PROGBITS[ ]+([[:xdigit:]]+[ ]+){4}WA[ ]+[[:digit:]]+.*
.* \.rela?\.test3[ ]+RELA?[ ]+.*
! .* \.test4[ ]+NOBITS[ ]+([[:xdigit:]]+[ ]+){4}WA[ ]+[[:digit:]]+.*
--- 1,8 ----
! .* \.test0[ ]+PROGBITS[ ]+[0-9a-fA-F]+[ ]+[0-9a-fA-F]+[ ]+[0-9a-fA-F]+[ ]+[0-9a-fA-F]+[ ]+[ ]+[0-9]+.*
! .* \.test1[ ]+PROGBITS[ ]+[0-9a-fA-F]+[ ]+[0-9a-fA-F]+[ ]+[0-9a-fA-F]+[ ]+[0-9a-fA-F]+[ ]+[ ]+[0-9]+.*
.* \.rela?\.test1[ ]+RELA?[ ]+.*
! .* \.test2[ ]+PROGBITS[ ]+[0-9a-fA-F]+[ ]+[0-9a-fA-F]+[ ]+[0-9a-fA-F]+[ ]+[0-9a-fA-F]+[ ]+[ ]+[0-9]+.*
.* \.rela?\.test2[ ]+RELA?[ ]+.*
! .* \.test3[ ]+PROGBITS[ ]+[0-9a-fA-F]+[ ]+[0-9a-fA-F]+[ ]+[0-9a-fA-F]+[ ]+[0-9a-fA-F]+[ ]+WA[ ]+[0-9]+.*
.* \.rela?\.test3[ ]+RELA?[ ]+.*
! .* \.test4[ ]+NOBITS[ ]+[0-9a-fA-F]+[ ]+[0-9a-fA-F]+[ ]+[0-9a-fA-F]+[ ]+[0-9a-fA-F]+[ ]+WA[ ]+[0-9]+.*
Index: section5.l
===================================================================
RCS file: /cvs/src/src/gas/testsuite/gas/elf/section5.l,v
retrieving revision 1.2
diff -c -p -r1.2 section5.l
*** section5.l 20 Dec 2004 15:35:53 -0000 1.2
--- section5.l 21 Dec 2004 05:24:06 -0000
***************
*** 11,37 ****
.*GAS.*
! [ ]+[[:digit:]]+[ ]+.section[ ]+.test0[ ]*
! [ ]+[[:digit:]]+[ ]+.section[ ]+.test1,[ ]*"",[ ]*%progbits[ ]*
! [ ]+[[:digit:]]+[ ]+.section[ ]+.test2[ ]*
! [ ]+[[:digit:]]+[ ]+.section[ ]+.test3,[ ]*"aw"[ ]*
! [ ]+[[:digit:]]+[ ]+.section[ ]+.test4,[ ]*"aw",[ ]*%nobits[ ]*
! [ ]+[[:digit:]]+[ ]*
! [ ]+[[:digit:]]+[ ]+.section[ ]+.test1,[ ]*"aw",[ ]*%nobits[ ]*
! [ ]+[[:digit:]]+[ ]+.*
! [ ]+[[:digit:]]+[ ]*
! [ ]+[[:digit:]]+[ ]+.section[ ]+.test2,[ ]*"w"[ ]*
! [ ]+[[:digit:]]+[ ]+.*
! [ ]+[[:digit:]]+[ ]*
! [ ]+[[:digit:]]+[ ]+.section[ ]+.test3,[ ]*"aw",[ ]*%progbits[ ]*
! [ ]+[[:digit:]]+[ ]+.*
! [ ]+[[:digit:]]+[ ]*
! [ ]+[[:digit:]]+[ ]+.section[ ]+.test4,[ ]*"aw"[ ]*
! [ ]+[[:digit:]]+[ ]*
! [ ]+[[:digit:]]+[ ]+.section[ ]+.data,[ ]*"a"[ ]*
! [ ]+[[:digit:]]+[ ]*
! [ ]+[[:digit:]]+[ ]+.section[ ]+.bss,[ ]*"a"[ ]*
! [ ]+[[:digit:]]+[ ]*
! [ ]+[[:digit:]]+[ ]+.section[ ]+.data,[ ]*"aw",[ ]*%nobits[ ]*
! [ ]+[[:digit:]]+[ ]*
! [ ]+[[:digit:]]+[ ]+.section[ ]+.bss,[ ]*"aw",[ ]*%progbits[ ]*
--- 11,37 ----
.*GAS.*
! [ ]+[0-9]+[ ]+.section[ ]+.test0[ ]*
! [ ]+[0-9]+[ ]+.section[ ]+.test1,[ ]*"",[ ]*%progbits[ ]*
! [ ]+[0-9]+[ ]+.section[ ]+.test2[ ]*
! [ ]+[0-9]+[ ]+.section[ ]+.test3,[ ]*"aw"[ ]*
! [ ]+[0-9]+[ ]+.section[ ]+.test4,[ ]*"aw",[ ]*%nobits[ ]*
! [ ]+[0-9]+[ ]*
! [ ]+[0-9]+[ ]+.section[ ]+.test1,[ ]*"aw",[ ]*%nobits[ ]*
! [ ]+[0-9]+[ ]+.*
! [ ]+[0-9]+[ ]*
! [ ]+[0-9]+[ ]+.section[ ]+.test2,[ ]*"w"[ ]*
! [ ]+[0-9]+[ ]+.*
! [ ]+[0-9]+[ ]*
! [ ]+[0-9]+[ ]+.section[ ]+.test3,[ ]*"aw",[ ]*%progbits[ ]*
! [ ]+[0-9]+[ ]+.*
! [ ]+[0-9]+[ ]*
! [ ]+[0-9]+[ ]+.section[ ]+.test4,[ ]*"aw"[ ]*
! [ ]+[0-9]+[ ]*
! [ ]+[0-9]+[ ]+.section[ ]+.data,[ ]*"a"[ ]*
! [ ]+[0-9]+[ ]*
! [ ]+[0-9]+[ ]+.section[ ]+.bss,[ ]*"a"[ ]*
! [ ]+[0-9]+[ ]*
! [ ]+[0-9]+[ ]+.section[ ]+.data,[ ]*"aw",[ ]*%nobits[ ]*
! [ ]+[0-9]+[ ]*
! [ ]+[0-9]+[ ]+.section[ ]+.bss,[ ]*"aw",[ ]*%progbits[ ]*
brgds, H-P