emacs-devel
[Top][All Lists]
Advanced

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

Re: beginning-of-defun (again)


From: David Kastrup
Subject: Re: beginning-of-defun (again)
Date: Sat, 31 Oct 2015 13:24:19 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux)

Andreas Röhler <address@hidden> writes:

>  On 31.10.2015 00:14, Richard Stallman wrote:
>> [[[ To any NSA and FBI agents reading my email: please consider    ]]]
>> [[[ whether defending the US Constitution against all enemies,     ]]]
>> [[[ foreign or domestic, requires you to follow Snowden's example. ]]]
>>
>>    >  With emacs -Q, C-M-a from behind example below, stops at "(bar)",
>>    >  missing the beginning of function.
>>
>>    >  (defun foo ()
>>    >     (insert "
>>    >  (bar)"))
>>
>> Our convention is that you should write it this way:
>>
>>     (defun foo ()
>>        (insert "
>>     \(bar)"))
>>
>
> A convention which probably predates Aristoteles :)
> Working-by-convention is rather a social thing...
>
> That design was a real nuisance  when generating and writing functions
> on the fly.
> Sure, it's possible to live with it. But why not remove that
> constraint, if possible?

Because reparsing every file from its beginning in order to indent the
current line is too expensive for large files?

The meaning of every Lisp file can be changed by putting

(setq everything "

at its beginning.  There really is no correct way to determine current
state apart from parsing from the start.  So we have a convention for an
"incorrect way" of avoiding parsing from the start.

-- 
David Kastrup



reply via email to

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