From: Tomas Volf <~@wolfsden.cz>
To: "32841" <32841@debbugs.gnu.org>
Cc: ".%c2.п." <2024110144@mails.szu.edu.cn>
Subject: bug#32841: assoc-set fails with dot notation association list
Date: Mon, 21 Oct 2024 22:26:48 +0200 [thread overview]
Message-ID: <875xpl8anr.fsf@wolfsden.cz> (raw)
In-Reply-To: <tencent_5CAC21567C7980F774C9E804@qq.com> (".%c2.п."'s message of "Mon, 21 Oct 2024 16:54:54 +0800")
".%c2.п." via "Bug reports for GUILE, GNU's Ubiquitous
Extension Language" <bug-guile@gnu.org> writes:
> The thread and all replies were in 2018. Six years later, in 2024, Anyone opening the up-to-date online manual still sees the old bad code there! The manual is not adjusted even though previous emails had pointed the cause and solution out!
> Today, the page has a valid link of https://www.gnu.org/software/guile/manual/html_node/Alist-Example.html and still contains
>
> 6.6.20.6 Alist Example
>
> Here is a longer example of how alists may be used in practice.
> (define capitals '(("New York" . "Albany") ("Oregon" . "Salem") ("Florida" . "Miami"))) ;; What's the capital of Oregon? (assoc "Oregon" capitals) ⇓ ("Oregon" . "Salem") (assoc-ref capitals "Oregon") ⇓ "Salem" ;; We left out South Dakota. (set! capitals (assoc-set! capitals "South Dakota" "Pierre")) capitals ⇓ (("South Dakota" . "Pierre") ("New York" . "Albany") ("Oregon" . "Salem") ("Florida" . "Miami")) ;; And we got Florida wrong. (set! capitals (assoc-set! capitals "Florida" "Tallahassee")) capitals ⇓ (("South Dakota" . "Pierre") ("New York" . "Albany") ("Oregon" . "Salem") ("Florida" . "Tallahassee")) ;; After Oregon secedes, we can remove it. (set! capitals (assoc-remove! capitals "Oregon")) capitals ⇓ (("South Dakota" . "Pierre") ("New York" . "Albany") ("Florida" . "Tallahassee"))
>
>
>
>
>
>
> 深圳大学
> 陈
> 有骏
Your message is really hard to read, I cannot make heads or tails of the
formatting. Could you please resend it formatted in a normal way? In
particular, wrapping your text to 72 characters and properly formatting
the code example will improve the readability a lot.
Have a nice day,
Tomas Volf
--
There are only two hard things in Computer Science:
cache invalidation, naming things and off-by-one errors.
next prev parent reply other threads:[~2024-10-21 20:26 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-09-25 20:33 bug#32841: assoc-set fails with dot notation association list Hood, Christopher L.
2018-09-25 22:04 ` John Cowan
2018-09-27 3:02 ` Mark H Weaver
2018-09-27 12:09 ` John Cowan
2024-10-21 8:54 ` ���п� via Bug reports for GUILE, GNU's Ubiquitous Extension Language
2024-10-21 20:26 ` Tomas Volf [this message]
2024-10-22 3:48 ` ���п� via Bug reports for GUILE, GNU's Ubiquitous Extension Language
2024-10-22 17:51 ` lloda
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/guile/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=875xpl8anr.fsf@wolfsden.cz \
--to=~@wolfsden.cz \
--cc=2024110144@mails.szu.edu.cn \
--cc=32841@debbugs.gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).