From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#66944: 30.0.50; [PATCH] make calc parse fractions written using U+2044 FRACTION SLASH Date: Sat, 27 Jan 2024 11:09:03 +0200 Message-ID: <861qa39m8g.fsf@gnu.org> References: <87o7g8r4t8.fsf@db48x.net> <87wmsdnrgw.fsf@db48x.net> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="35594"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 66944@debbugs.gnu.org, stefankangas@gmail.com To: Daniel Brooks Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Jan 27 10:10:18 2024 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 1rTehd-00094T-Qr for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 27 Jan 2024 10:10:17 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rTehK-0001nH-DQ; Sat, 27 Jan 2024 04:09:58 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rTehH-0001lH-Sf for bug-gnu-emacs@gnu.org; Sat, 27 Jan 2024 04:09:56 -0500 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rTehH-0008SE-AK for bug-gnu-emacs@gnu.org; Sat, 27 Jan 2024 04:09:55 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rTehO-00067S-7r for bug-gnu-emacs@gnu.org; Sat, 27 Jan 2024 04:10:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 27 Jan 2024 09:10:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 66944 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 66944-submit@debbugs.gnu.org id=B66944.170634656223469 (code B ref 66944); Sat, 27 Jan 2024 09:10:02 +0000 Original-Received: (at 66944) by debbugs.gnu.org; 27 Jan 2024 09:09:22 +0000 Original-Received: from localhost ([127.0.0.1]:53442 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rTegk-00066T-9F for submit@debbugs.gnu.org; Sat, 27 Jan 2024 04:09:22 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:44312) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rTegh-00066G-Fk for 66944@debbugs.gnu.org; Sat, 27 Jan 2024 04:09:20 -0500 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rTegV-0008OK-1p; Sat, 27 Jan 2024 04:09:07 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=yJIVnsdrsl8L/wt6H9dYuxJGK8jpqpQRfidzGZ1kJYk=; b=qKSxoxGBB4sxOFyzLf4/ /ST0paQH396LQrPSNQNLUyCKSFpSxt+ei5dIHwbhnFAVoq6ZxO2aF3gdK3iJZUdPMCS0MJGbKns8N UqnHb1Br3EkhyYUTNNyGqRs4lgsch31VJj/ENti4ypIUYP00B/K6y3WQ1Tl/yYAe/QbcIkf01QNEZ jjLW/DauWcJby87MBDAsMpHDKbGHVL7hxzBNL8jR64LUp42F93EQn8xChoCAxRTPedB3J6L6MgFbU DHwrfZlYs4PUlRf9ZeJDVT/K4w2oIBASI1PeguYKP9r0dHga6y2O46e3bIaRHWbpLDPDozYS3E5Fh XvgQawz1X6/OrA==; In-Reply-To: <87wmsdnrgw.fsf@db48x.net> (message from Daniel Brooks on Sat, 13 Jan 2024 08:11:27 -0800) 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-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:278974 Archived-At: > Cc: 66944@debbugs.gnu.org > From: Daniel Brooks > Date: Sat, 13 Jan 2024 08:11:27 -0800 > > Stefan Kangas writes: > > > Daniel Brooks writes: > > > >> Fractions written as `2:3', `2÷3', and `⅔' are all parsed as rational > >> fractions; `2⁄3' ought to do the same. > > > > Thanks, but was the intention here to attach a patch? > > > > I can't see one attached, so maybe you missed it. > > /me facepalms > > Yea, dunno how that happened. Let me try again, this time with my tongue > held at just the right angle… Thanks, and apologies for a delay in reviewing the patch. I have some minor comments below, but I also see that we have no copyright assignment from you, and without that we will be unable to accept contributions from you after this one. Would you like to start the paperwork of assigning the copyright to the FSF at this time, so we could accept contributions from you in the future? > --- a/doc/misc/calc.texi > +++ b/doc/misc/calc.texi > @@ -10571,6 +10571,12 @@ Fractions > @samp{@var{radix}#@var{num}:@var{denom}} (or in the analogous three-part > form). The numerator and denominator always use the same radix. > > +Fractions may also be entered with @kbd{⁄} (U+2044 FRACTION SLASH) in > +place of any @kbd{:}. Precomposed fraction characters from @kbd{½} > +(U+00BD VULGAR FRACTION ONE HALF) through @kbd{⅞} (U+215E VULGAR > +FRACTION SEVEN EIGHTHS) as supported as well. Thus @samp{2:3}, > +@samp{2⁄3}, and @samp{⅔} are all equivalent. Please try rewriting these to avoid non-ASCII characters in Texinfo source files, since processing those with TeX could cause problems. Where possible, please use the special Texinfo commands described in the "Insertions" chapter of the Texinfo manual and its sections. If some character cannot be written using ASCII characters as described in that section, please just name it, as in "U+2044 FRACTION SLASH", but don't include it verbatim. Also, our conventions are to leave two spaces between sentences in documentation and comments (this is relevant to the NEWS entry as well). > --- a/etc/NEWS > +++ b/etc/NEWS > @@ -983,7 +983,12 @@ URIs are now prefixed with "https://" instead. > +++ > *** New command 'customize-dirlocals'. > This command pops up a buffer to edit the settings in ".dir-locals.el". > - > +** Calc > +*** Calc parses fractions written using U+2044 FRACTION SLASH > +Fractions of the form 123⁄456 are handled as if written 123:456. Note > +in particular the difference in behavior from U+2215 DIVISION SLASH > +and U+002F SOLIDUS, which result in division rather than a rational > +fraction. This entry should be marked with "+++", as the necessary manual changes were made. Also, this doesn't mention the precomposed fractions; I think it should. Thanks.