Path: csiph.com!3.us.feeder.erje.net!feeder.erje.net!news.linkpendium.com!news.linkpendium.com!panix!usenet.stanford.edu!not-for-mail From: Ilkka Virta Newsgroups: gnu.bash.bug Subject: Re: Arithmetic evaluation of negative numbers with base prefix Date: Tue, 18 Jun 2019 19:13:26 +0300 Lines: 31 Approved: bug-bash@gnu.org Message-ID: References: <20190614141947.GB27242@tower> <20190617133026.GC27242@tower> <20190617154708.GG2072@eeg.ccf.org> <20190618152013.GM2072@eeg.ccf.org> NNTP-Posting-Host: lists.gnu.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-Trace: usenet.stanford.edu 1560874432 32382 209.51.188.17 (18 Jun 2019 16:13:52 GMT) X-Complaints-To: action@cs.stanford.edu To: bug-bash@gnu.org Envelope-to: bug-bash@gnu.org User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.11; rv:60.0) Gecko/20100101 Thunderbird/60.7.1 In-Reply-To: <20190618152013.GM2072@eeg.ccf.org> Content-Language: en-US X-SASI-RCODE: 200 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=iki.fi; h=subject:to:references:from:message-id:date:mime-version:in-reply-to:content-type:content-transfer-encoding; s=smtp; bh=f5eSkLRxEyMfag6lITVLz5edxJ/DPYUIWVsTaItIni0=; b=WJxQYaz1VoOMAx82GfFPQRGhBgHk5u2yq/Ec6LAiTadkyBlGJcKyeMFAYYMrIrMyDPdIViWIFC/tfJE3XUaFYrpuCqt3hJP+VB+5s0IsFALzppIobp0R0yIkGWb2rTo3V0tHnuZX4eSVgzU9tWvNfF6PfGh2uudkffVHr3QaR2n9bpXAuYIPW6yp6s01+1FGWT6OPqGsv/8L7acrLWIKpvWzO6DW/ZG6aSkgpz/7FPSbGM/9Aw7E1EuNGHw7Aind4wPjZGx9lC+H/MB+kTe8omzkxUz/2R5wHxD1ynF7WjVDbvt21AM5kOg+Wwe9stWBKuJ+dk2v8OUcAfGs5Ckudg== X-detected-operating-system: by eggs.gnu.org: FreeBSD 8.x X-Received-From: 157.24.2.213 X-BeenThere: bug-bash@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Bug reports for the GNU Bourne Again SHell List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Mailman-Original-Message-ID: X-Mailman-Original-References: <20190614141947.GB27242@tower> <20190617133026.GC27242@tower> <20190617154708.GG2072@eeg.ccf.org> <20190618152013.GM2072@eeg.ccf.org> Xref: csiph.com gnu.bash.bug:15057 On 18.6. 18:20, Greg Wooledge wrote: > On Tue, Jun 18, 2019 at 10:27:48AM -0400, Chet Ramey wrote: >> $ ksh93 -c 'echo ${.sh.version}' >> Version ABIJM 93v- 2014-09-29 >> $ ksh93 -c 'echo $(( 10# ))' >> ksh93: 10# : arithmetic syntax error > > I guess most Linux distributions are not shipping the 2014 version of > ksh93 yet...? Yeah, I had the one from Debian. I'm not even sure what the current version of ksh is. At least the newer versions throw an error instead of silently doing the unexpected. > wooledg:~$ ksh -c 'echo $(( 10# ))' > 0 > wooledg:~$ dpkg -l ksh | tail -1 > ii ksh 93u+20120801-3.4 amd64 Real, AT&T version of the Korn shell > wooledg:~$ ksh -c 'echo ${.sh.version}' > Version AJM 93u+ 2012-08-01 > > Seems kinda weird to continue calling it "ksh93" if it's being changed, > but I don't make the decisions. > -- Ilkka Virta / itvirta@iki.fi