[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: master f51f963: Fix some side-effecting uses of make-text-button

From: Pip Cet
Subject: Re: master f51f963: Fix some side-effecting uses of make-text-button
Date: Sun, 07 Jun 2020 09:14:06 +0000
User-agent: Gnus/5.13 (Gnus v5.13)

Paul Eggert <eggert@cs.ucla.edu> writes:

>> consider quasi-quoted literals: would those be immutable?
> A string literal should not be modified, regardless of whether it's
> quasiquoted.
> A subexpression of `X that contains no substitutions or splices yields conses
> that should not be modified.
> These two rules are reasonably simple and are already documented, and neither
> rule should be that hard to remember for the few people whose code is affected
> by this issue.

Okay. It's a situation I was unsure about myself, but if these are the
rules, they are easy enough to remember.

>> It would lead to some people developing a false sense of security
> "False sense" because programmers would start relying on Emacs to
> catch trivial
> mistakes involving modifying string literals? Horrors! (Programmers should let
> those mistakes persist into hard-to-debug complex programs, as this will give
> them much more of a challenge when debugging. :-)

I'm not sure programmers would realize those errors are caught only at
run time, rather than being detected at compile time, which they could
be in many cases.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]