emacs-bug-tracker
[Top][All Lists]
Advanced

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

[debbugs-tracker] bug#24800: closed (expr 8.25 seems to treat 0 in chara


From: GNU bug Tracking System
Subject: [debbugs-tracker] bug#24800: closed (expr 8.25 seems to treat 0 in character class in paren incorrectly)
Date: Wed, 26 Oct 2016 16:16:01 +0000

Your message dated Wed, 26 Oct 2016 09:15:22 -0700
with message-id <address@hidden>
and subject line Re: bug#24800: expr 8.25 seems to treat 0 in character class 
in paren incorrectly
has caused the debbugs.gnu.org bug report #24800,
regarding expr 8.25 seems to treat 0 in character class in paren incorrectly
to be marked as done.

(If you believe you have received this mail in error, please contact
address@hidden)


-- 
24800: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=24800
GNU Bug Tracking System
Contact address@hidden with problems
--- Begin Message --- Subject: expr 8.25 seems to treat 0 in character class in paren incorrectly Date: Wed, 26 Oct 2016 15:13:09 +0900
Hello, coreutils maintainers.

Command expr in version 8.25 of coreutils seems for me to treat
0 in character class in paren incorrectly.
$ for i in {a..z}; do expr $i : '\([a-z]\)$' >/dev/null || echo failed at $i; 
done
$ for i in {1..9}; do expr $i : '\([1-9]\)$' >/dev/null || echo failed at $i; 
done
$ for i in {0..9}; do expr $i : '[0-9]$'     >/dev/null || echo failed at $i; 
done
$ for i in {0..9}; do expr $i : '\([0-9]\)$' >/dev/null || echo failed at $i; 
done
failed at 0
$ for i in / 0 1 ; do expr $i : '\([/-1]\)$' >/dev/null || echo failed at $i; 
done
failed at 0
$ for i in . / 0 ; do expr $i : '\([.-0]\)$' >/dev/null || echo failed at $i; 
done
failed at 0
$ for i in {00..99}; do expr $i : '\([0-9][0-9]\)$' >/dev/null || echo failed 
at $i; done
failed at 00
$ for i in {000..999}; do expr $i : '\([0-9][0-9][0-9]\)$' >/dev/null || echo 
failed at $i; done
failed at 000

machine architecture:
Linux doraemon2 2.6.32-431.el6.x86_64 #1 SMP Fri Nov 22 03:15:
09 UTC 2013 x86_64 GNU/Linux

Thank you in advance.
Due to security policy of my company, I cannot use To and CC fields.
Sorry for inconvenience.
--
  iida



--- End Message ---
--- Begin Message --- Subject: Re: bug#24800: expr 8.25 seems to treat 0 in character class in paren incorrectly Date: Wed, 26 Oct 2016 09:15:22 -0700 User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.4.0 There's no bug here: "expr E" exits with status 1 if E evaluates to 0, and expressions like "0 : '\([0-9]\)$'" do evaluate to 0.


--- End Message ---

reply via email to

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