From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Mattias =?UTF-8?Q?Engdeg=C3=A5rd?= Newsgroups: gmane.emacs.bugs Subject: bug#37140: 27.0.50; calc gives "Wrong type argument: number-or-marker-p, inf" to many operations Date: Sat, 24 Aug 2019 20:38:42 +0200 Message-ID: References: <82A27C89-ECB1-43A3-8A7D-AF49158EA1E0@acm.org> <83pnkuivwy.fsf@gnu.org> <83o90eivq4.fsf@gnu.org> Mime-Version: 1.0 (Mac OS X Mail 12.4 \(3445.104.11\)) Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="162070"; mail-complaints-to="usenet@blaine.gmane.org" Cc: 37140@debbugs.gnu.org, huszaghmatt@gmail.com, npostavs@gmail.com To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sat Aug 24 20:39:11 2019 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1i1awQ-000g35-Un for geb-bug-gnu-emacs@m.gmane.org; Sat, 24 Aug 2019 20:39:11 +0200 Original-Received: from localhost ([::1]:39010 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1i1awP-0006DB-89 for geb-bug-gnu-emacs@m.gmane.org; Sat, 24 Aug 2019 14:39:09 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:48756) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1i1awJ-0006D4-FZ for bug-gnu-emacs@gnu.org; Sat, 24 Aug 2019 14:39:04 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1i1awI-0003yE-Gu for bug-gnu-emacs@gnu.org; Sat, 24 Aug 2019 14:39:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:34470) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1i1awI-0003y7-EC for bug-gnu-emacs@gnu.org; Sat, 24 Aug 2019 14:39:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1i1awI-0003Ku-8h for bug-gnu-emacs@gnu.org; Sat, 24 Aug 2019 14:39:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Mattias =?UTF-8?Q?Engdeg=C3=A5rd?= Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 24 Aug 2019 18:39:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 37140 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: notabug Original-Received: via spool by 37140-submit@debbugs.gnu.org id=B37140.156667193012797 (code B ref 37140); Sat, 24 Aug 2019 18:39:02 +0000 Original-Received: (at 37140) by debbugs.gnu.org; 24 Aug 2019 18:38:50 +0000 Original-Received: from localhost ([127.0.0.1]:43291 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1i1aw5-0003KK-Ld for submit@debbugs.gnu.org; Sat, 24 Aug 2019 14:38:49 -0400 Original-Received: from mail76c50.megamailservers.eu ([91.136.10.86]:34590 helo=mail70c50.megamailservers.eu) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1i1aw2-0003K7-Sw for 37140@debbugs.gnu.org; Sat, 24 Aug 2019 14:38:48 -0400 X-Authenticated-User: mattiase@bredband.net DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=megamailservers.eu; s=maildub; t=1566671925; bh=KvZLp5UJMI/qhRlZu4ria/ZT2RrMOyNw6qFXWmEq0MI=; h=Subject:From:In-Reply-To:Date:Cc:References:To:From; b=RksCZSLDxpRXdiq6yMw0odVT1Dvq2YVMrdvuootWPo/yQH0HZ9PmP37SBMBle2grk wobI3JuMHsMS2WGccj4ve75T+D+7Bufc7ZUwYILEEfcrW55rvogpq8X5hmPxg03rXR w1EU9CKNxBvhOY4x4YCJlvgClVqciGZPGiZSlUDs= Feedback-ID: mattiase@acm.or Original-Received: from [192.168.1.64] (c-e636e253.032-75-73746f71.bbcust.telenor.se [83.226.54.230]) (authenticated bits=0) by mail70c50.megamailservers.eu (8.14.9/8.13.1) with ESMTP id x7OIcgep024681; Sat, 24 Aug 2019 18:38:44 +0000 In-Reply-To: <83o90eivq4.fsf@gnu.org> X-Mailer: Apple Mail (2.3445.104.11) X-CTCH-RefID: str=0001.0A0B0212.5D618435.0005, ss=1, re=0.000, recu=0.000, reip=0.000, cl=1, cld=1, fgs=0 X-CTCH-VOD: Unknown X-CTCH-Spam: Unknown X-CTCH-Score: 0.000 X-CTCH-Flags: 0 X-CTCH-ScoreCust: 0.000 X-CSC: 0 X-CHA: v=2.3 cv=OLYJIxSB c=1 sm=1 tr=0 a=M+GU/qJco4WXjv8D6jB2IA==:117 a=M+GU/qJco4WXjv8D6jB2IA==:17 a=jpOVt7BSZ2e4Z31A5e1TngXxSK0=:19 a=IkcTkHD0fZMA:10 a=M51BFTxLslgA:10 a=RBnWMRkBankkammTdMoA:9 a=QEXdDO2ut3YA:10 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:165787 Archived-At: The bug could indeed be reproduced with gcc 9.1.1, and turned out to be = caused by -ffinite-math-only which -Ofast includes. This option allows = the compiler to assume that no number is infinity or NaN. This causes printing =C2=B1Inf to misbehave since the standard isinf = function now always returns false, and 1.0e+INF is printed as "inf" when = generating the constant pool in the byte-compiled function. When this = byte-code is loaded, the value is read back as the lisp symbol `inf' = which caused the error we saw. The precise location is in the initialisation of = math-largest-emacs-expt; the error occurs during load time, but the = damage was already done by float_to_string when calc-math.elc was = generated. In other words, the route to the error was somewhat roundabout, but it = looks like there is no actual bug in Emacs nor in gcc. But at least I = didn't know that, and was enlightened by the result.