GNU bug report logs - #66656
Bug reports

Previous Next

Package: emacs;

Reported by: Lewis Creary <lewcreary <at> cs.com>

Date: Fri, 20 Oct 2023 21:45:02 UTC

Severity: normal

Tags: notabug

Done: Stefan Kangas <stefankangas <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


Message #8 received at 66656 <at> debbugs.gnu.org (full text, mbox):

From: Stephen Berman <stephen.berman <at> gmx.net>
To: Lewis Creary via "Bug reports for GNU Emacs, the Swiss army knife of
 text editors" <bug-gnu-emacs <at> gnu.org>
Cc: 66656 <at> debbugs.gnu.org, Lewis Creary <lewcreary <at> cs.com>
Subject: Re: bug#66656: Bug reports
Date: Sat, 21 Oct 2023 00:06:55 +0200
On Fri, 20 Oct 2023 21:42:25 +0000 (UTC) Lewis Creary via "Bug reports for GNU Emacs, the Swiss army knife of text editors" <bug-gnu-emacs <at> gnu.org> wrote:

[...]
> The main bug I'm reporting consists in the fact that recently, when I
> tried to test the lisp function displayed just below, I triggered the
> lisp error message "`let' bindings can have only one value-form", when
> it is clear from inspection of the let* form in question that no such
> bug exists.  The let* form in question does have just one value-form,
> the lisp variable eight-powr-sum..
>
> (defun octal-to-dec (n)
>   (let* ((oct-str {number-to-string n)
>          (octal-digits (string-to-reverse-numlist oct-str))
>          (oct-digit nil)
>          (eight-powr-term-val 0)
>          (eight-powr-sum 0)
>          (indx 0)
>          (while-nil-val (while (<= indx (length octal-digits))
>            (setq oct-digit (nth indx octal-digits)
>                  eight-powr-term-val (* oct-digit (expt 8 indx))
>                  eight-powr-sum (+ eight-powr-sum eight-powr-term-val)
>                  indx (1+ index) ))) ) ; end of let-variables
>      eight-powr-sum )))

The error is because the first let-binding binds `oct-str' to both
`{number-to-string' and `n'.  I guess `{' is a typo for `(' and there
should also be a closing `)': `(oct-str (number-to-string n))'.

Steve Berman




This bug report was last modified 1 year and 147 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.