From owner-freebsd-hackers Mon Jun 9 17:51:17 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.5/8.8.5) id RAA25585 for hackers-outgoing; Mon, 9 Jun 1997 17:51:17 -0700 (PDT) Received: from genesis.atrad.adelaide.edu.au (genesis.atrad.adelaide.edu.au [129.127.96.120]) by hub.freebsd.org (8.8.5/8.8.5) with ESMTP id RAA25577 for ; Mon, 9 Jun 1997 17:51:13 -0700 (PDT) Received: (from msmith@localhost) by genesis.atrad.adelaide.edu.au (8.8.5/8.7.3) id JAA02000; Tue, 10 Jun 1997 09:32:38 +0930 (CST) From: Michael Smith Message-Id: <199706100002.JAA02000@genesis.atrad.adelaide.edu.au> Subject: Re: %i conversion in sscanf? In-Reply-To: <19970609223442.26371@keltia.freenix.fr> from Ollivier Robert at "Jun 9, 97 10:34:42 pm" To: roberto@keltia.freenix.fr (Ollivier Robert) Date: Tue, 10 Jun 1997 09:32:37 +0930 (CST) Cc: hackers@FreeBSD.ORG X-Mailer: ELM [version 2.4ME+ PL28 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-hackers@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk Ollivier Robert stands accused of saying: > According to Michael Smith: > > It's "fairly" clear that %i might be expected to convert 0xABCDEF45 > > to a negative number - Tcl thinks that way : > > > > silver:/tmp>tclsh > > % expr 0xABCDEF45 > > -1412567227 > > Interesting: > > 244 [22:29] roberto@keltia:~> perl -e 'print 0xABCDEF45 . "\n"' > 2882400069 > > Perl 5.004 Hmm. What internal type does Perl use for numbers? Or does it decide that the constant is too big and use a bignum? > Ollivier ROBERT -=- FreeBSD: There are no limits -=- roberto@keltia.freenix.fr -- ]] Mike Smith, Software Engineer msmith@gsoft.com.au [[ ]] Genesis Software genesis@gsoft.com.au [[ ]] High-speed data acquisition and (GSM mobile) 0411-222-496 [[ ]] realtime instrument control. (ph) +61-8-8267-3493 [[ ]] Unix hardware collector. "Where are your PEZ?" The Tick [[