From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: "Lars J. Aas" Newsgroups: gmane.lisp.guile.devel Subject: Re: SCM_POSFIXABLE(-1) fails with MSVC++ 6.0 Date: Thu, 22 Aug 2002 15:47:20 +0200 Sender: guile-devel-admin@gnu.org Message-ID: <20020822134720.GB16177@sim.no> References: <20020822133052.GA16177@sim.no> NNTP-Posting-Host: localhost.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: main.gmane.org 1030024021 11287 127.0.0.1 (22 Aug 2002 13:47:01 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Thu, 22 Aug 2002 13:47:01 +0000 (UTC) Return-path: Original-Received: from monty-python.gnu.org ([199.232.76.173]) by main.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 17hsId-0002vp-00 for ; Thu, 22 Aug 2002 15:46:59 +0200 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.10) id 17hsJl-00071N-00; Thu, 22 Aug 2002 09:48:09 -0400 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.10) id 17hsJ2-0006ut-00 for guile-devel@gnu.org; Thu, 22 Aug 2002 09:47:24 -0400 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.10) id 17hsJ0-0006uh-00 for guile-devel@gnu.org; Thu, 22 Aug 2002 09:47:23 -0400 Original-Received: from trh.sim.no ([213.236.166.75] helo=sim.no) by monty-python.gnu.org with smtp (Exim 4.10) id 17hsIz-0006uc-00 for guile-devel@gnu.org; Thu, 22 Aug 2002 09:47:21 -0400 Original-Received: (qmail 16615 invoked by uid 2000); 22 Aug 2002 13:47:20 -0000 Original-To: Guile Devel Content-Disposition: inline In-Reply-To: <20020822133052.GA16177@sim.no> User-Agent: Mutt/1.3.24i Errors-To: guile-devel-admin@gnu.org X-BeenThere: guile-devel@gnu.org X-Mailman-Version: 2.0.11 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: Developers list for Guile, the GNU extensibility library List-Unsubscribe: , List-Archive: Xref: main.gmane.org gmane.lisp.guile.devel:1138 X-Report-Spam: http://spam.gmane.org/gmane.lisp.guile.devel:1138 Lars J. Aas wrote: : #ifdef LONG_BIT : # define SCM_LONG_BIT LONG_BIT : #else : # define SCM_LONG_BIT (SCM_CHAR_BIT * sizeof (long) / sizeof (char)) : #endif I boiled the problem down to this test failing: fprintf(stderr, "testing directly if -1 is <= sizeof(long) "); if ( -1 <= sizeof(long) ) fprintf(stderr, "true\n"); else fprintf(stderr, "not so!\n"); Changing the alternative definition of SCM_LONG_BITS to cast the value to long like this works... # define SCM_LONG_BIT ((long)(SCM_CHAR_BIT * sizeof (long) / sizeof (char))) Lars J _______________________________________________ Guile-devel mailing list Guile-devel@gnu.org http://mail.gnu.org/mailman/listinfo/guile-devel