From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 1027 invoked from network); 12 Aug 2000 00:41:57 -0000 Received: from ns2.primenet.com.au (HELO primenet.com.au) (?AgQzKc1IemoiV9Rd2x0XVdogDQx9B5rW?@203.24.36.3) by ns1.primenet.com.au with SMTP; 12 Aug 2000 00:41:57 -0000 Received: (qmail 5155 invoked from network); 11 Aug 2000 20:16:51 -0000 Received: from sunsite.auc.dk (130.225.51.30) by ns2.primenet.com.au with SMTP; 11 Aug 2000 20:16:51 -0000 Received: (qmail 18009 invoked by alias); 11 Aug 2000 20:15:32 -0000 Mailing-List: contact zsh-workers-help@sunsite.auc.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 12599 Received: (qmail 18002 invoked from network); 11 Aug 2000 20:15:31 -0000 Subject: Re: PATCH: C_BASES option for outputting hex and octal In-Reply-To: <0FZ300DOM3N03H@la-la.cambridgesiliconradio.com> from Peter Stephenson at "Aug 10, 2000 05:11:24 pm" To: Peter Stephenson Date: Fri, 11 Aug 2000 21:16:03 +0100 (BST) CC: Zsh hackers list X-Mailer: ELM [version 2.4ME+ PL66 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Message-Id: From: Zefram Peter Stephenson wrote: >Does anyone object to my adding options for trivial things like this? >Because if so they ought to have got the point and given up objecting years >ago :-/. (I finally got fed up with 0x${$(([#16]$num))##*\#}.) Wouldn't it be nicer to have $(([#0x]$num)) do the 0x-prefixed output, or some equivalent syntax? It'd be nicer not to have to fiddle with a global option to control an essentially local decision. Hmm. Perhaps a better way to do this kind of syntax would be to have a flag to say "don't output a radix prefix", so you'd do "0x$(([#16-]$num))" to get the 0x prefix. This is more flexible too, there are plenty of situations where you want non-decimal output without any standard prefix. -zefram