From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Mattias =?UTF-8?Q?Engdeg=C3=A5rd?= Newsgroups: gmane.emacs.bugs Subject: bug#43764: Calc shift right broken Date: Tue, 13 Oct 2020 11:56:50 +0200 Message-ID: <550C4DEF-DBAA-4175-98BC-DB484A3B89CF@acm.org> References: <87h7r9ozuh.fsf@gnus.org> <87wo04nnvr.fsf@gnus.org> Mime-Version: 1.0 (Mac OS X Mail 12.4 \(3445.104.17\)) Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="30855"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Lars Ingebrigtsen , 43764-done@debbugs.gnu.org To: Vincent =?UTF-8?Q?Bela=C3=AFche?= Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Oct 13 11:59:09 2020 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kSH5J-0007vg-2c for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 13 Oct 2020 11:59:09 +0200 Original-Received: from localhost ([::1]:60186 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kSH5I-0001Iu-4j for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 13 Oct 2020 05:59:08 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:46096) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kSH4E-00012e-PG for bug-gnu-emacs@gnu.org; Tue, 13 Oct 2020 05:58:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:33703) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kSH4E-00077w-Ew for bug-gnu-emacs@gnu.org; Tue, 13 Oct 2020 05:58:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kSH4E-0004gA-Df for bug-gnu-emacs@gnu.org; Tue, 13 Oct 2020 05:58:02 -0400 Resent-From: Mattias =?UTF-8?Q?Engdeg=C3=A5rd?= Original-Sender: "Debbugs-submit" Resent-To: bug-gnu-emacs@gnu.org Resent-Date: Tue, 13 Oct 2020 09:58:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: cc-closed 43764 X-GNU-PR-Package: emacs Mail-Followup-To: 43764@debbugs.gnu.org, mattiase@acm.org, vincent.b.1@hotmail.fr Original-Received: via spool by 43764-done@debbugs.gnu.org id=D43764.160258302217905 (code D ref 43764); Tue, 13 Oct 2020 09:58:02 +0000 Original-Received: (at 43764-done) by debbugs.gnu.org; 13 Oct 2020 09:57:02 +0000 Original-Received: from localhost ([127.0.0.1]:45249 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kSH3G-0004ee-4b for submit@debbugs.gnu.org; Tue, 13 Oct 2020 05:57:02 -0400 Original-Received: from mail1473c50.megamailservers.eu ([91.136.14.73]:52978 helo=mail102c50.megamailservers.eu) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kSH3D-0004eB-DN for 43764-done@debbugs.gnu.org; Tue, 13 Oct 2020 05:57:01 -0400 X-Authenticated-User: mattiase@bredband.net DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=megamailservers.eu; s=maildub; t=1602583012; bh=TaRtV0WTi4AqBSdtknjaETMEDy2b3C1It32zd7AVOCc=; h=Subject:From:In-Reply-To:Date:Cc:References:To:From; b=pdD4OimBAGLQm8cXn+rlRLVgTJR+T7HBx5ng6BkEl5cRnCcNcZTbjiSIFiQGV8lA9 XCvLWnnK8eXuM9Vl7wTilap+Bd6D7UAHNoYpJVknq5xQnLuATE5yPg6H+8cY2m/+jA mthoiIYq4HvToNHCYIWFomzZ1+c5k4HdnKRW5yQQ= Feedback-ID: mattiase@acm.or Original-Received: from [192.168.0.4] (c188-150-171-71.bredband.comhem.se [188.150.171.71]) (authenticated bits=0) by mail102c50.megamailservers.eu (8.14.9/8.13.1) with ESMTP id 09D9uoLM018885; Tue, 13 Oct 2020 09:56:52 +0000 In-Reply-To: X-Mailer: Apple Mail (2.3445.104.17) X-CTCH-RefID: str=0001.0A782F16.5F8579E4.009A, 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=S52nP7kP c=1 sm=1 tr=0 a=SF+I6pRkHZhrawxbOkkvaA==:117 a=SF+I6pRkHZhrawxbOkkvaA==:17 a=IkcTkHD0fZMA:10 a=M51BFTxLslgA:10 a=W3E8kTQ6JjtYGj2Bow0A:9 a=QEXdDO2ut3YA:10 X-Origin-Country: SE X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:190408 Archived-At: 9 okt. 2020 kl. 17.34 skrev Vincent Bela=C3=AFche = : > =E2=80=A2 set bit width 0 would remove the automatic clipping = meaning infinite width. The previously mentioned patch implementing this has now been pushed to = Emacs master. Thanks again for the suggestion! I should also note the rationale for disabling left/right rotation when = the word size is set to zero: while it would make sense to define (rotate-left x 1) =3D> x=E2=89=A50: (shift-left x 1) x<0: (+ (shift-left x 1) 1) (rotate-right x 1) =3D> x=E2=89=A50, x even: (shift-right x 1) x<0, x odd: (shift-right x 1), the two remaining cases of rotate right with {x=E2=89=A50, x odd} or = {x<0, x even} cannot result in a finite integer. If someone has a better idea, or would like rotation to be implemented = as a partial function according to the above definition, please comment. = For now the bug is closed.