* emacs coding modes need 'Suspend Disbelief' button
@ 2017-05-19 10:54 Jason Vas Dias
2017-05-19 11:20 ` tomas
` (4 more replies)
0 siblings, 5 replies; 8+ messages in thread
From: Jason Vas Dias @ 2017-05-19 10:54 UTC (permalink / raw)
To: emacs-devel, help-gnu-emacs
Hi Emacs wizards -
I just thought I should let you know,
being an emacs user of over 20 years,
that I think the fact that it is possible
to core-dump emacs by simply adding
some text to a shell script is bad , and
that I think modern emacs is going too
far in continuously syntax-checking
and parsing code.
In general, when using programming modes
such as c-mode / cc-mode / shell-script-mode ,
I wish, when typing, I could just turn all syntax
checking off by clicking on a 'Suspend Disbelief'
or 'Syntax Check Off' button / checkbox -
then, when I enter '"' or "'", the rest of the text
would not be colored - this is really annoying and greatly
slows down editing of large files - I don't want
the cursor to jump to the previous open bracket,
and I want the current indent to be preserved, until
I un-check 'Syntax Check' or press 'Syntax Check On' .
The insistence of modern emacs on always unconditionally
syntax checking everything greatly slows down typing and
is a major inhibition to quick editing of large source files .
And in some modes, such as shell script mode, and also
cc-mode, it is still possible to core-dump Emacs (latest 25.2 version)
simply by entering partial source code too slow or too fast , because of this
continuous syntax-checking .
I have core-dumped emacs several times recently by doing this -
one example that works pretty reliably is to start defining a
function within a function in shell-script - there is a timing
related bug , if you don't enter the opening '{' fast enough,
emacs will core-dump .
Emacs is regressing back towards 1990s levels of reliability
because of its insistence on continuous syntax checking .
Is there any way to globally turn off continuous syntax checking
for all modes ?
If not, I'm going to develop one.
Thanks & Regards,
Jason
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: emacs coding modes need 'Suspend Disbelief' button
2017-05-19 10:54 emacs coding modes need 'Suspend Disbelief' button Jason Vas Dias
@ 2017-05-19 11:20 ` tomas
[not found] ` <CALyZvKzvUBe1-+yTnpK97MA=Dh5q89RmTugG3CJ0bcrbqnd2Eg@mail.gmail.com>
2017-05-19 11:42 ` Óscar Fuentes
` (3 subsequent siblings)
4 siblings, 1 reply; 8+ messages in thread
From: tomas @ 2017-05-19 11:20 UTC (permalink / raw)
To: help-gnu-emacs
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Fri, May 19, 2017 at 10:54:28AM +0000, Jason Vas Dias wrote:
> Hi Emacs wizards -
[...]
> In general, when using programming modes
> such as c-mode / cc-mode / shell-script-mode ,
> I wish, when typing, I could just turn all syntax
> checking off by clicking on a 'Suspend Disbelief'
> or 'Syntax Check Off' button [...]
Not a button, but perhaps the start of one: does
"M-x fundamental-mode <RET>" float your boat?
cheers
- -- tomás
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)
iEYEARECAAYFAlke1OQACgkQBcgs9XrR2kYP8wCfTm7mgSiLJkj+c0Cn/RA4qeWN
RO0An004YYtgyvmmfDZL38MTGhbW1FUb
=p/Ei
-----END PGP SIGNATURE-----
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: emacs coding modes need 'Suspend Disbelief' button
2017-05-19 10:54 emacs coding modes need 'Suspend Disbelief' button Jason Vas Dias
2017-05-19 11:20 ` tomas
@ 2017-05-19 11:42 ` Óscar Fuentes
2017-05-19 11:45 ` hector
` (2 subsequent siblings)
4 siblings, 0 replies; 8+ messages in thread
From: Óscar Fuentes @ 2017-05-19 11:42 UTC (permalink / raw)
To: help-gnu-emacs; +Cc: emacs-devel
Jason Vas Dias <jason.vas.dias@gmail.com> writes:
> And in some modes, such as shell script mode, and also
> cc-mode, it is still possible to core-dump Emacs (latest 25.2 version)
> simply by entering partial source code too slow or too fast , because of this
> continuous syntax-checking .
> I have core-dumped emacs several times recently by doing this -
> one example that works pretty reliably is to start defining a
> function within a function in shell-script - there is a timing
> related bug , if you don't enter the opening '{' fast enough,
> emacs will core-dump .
Please use M-x report-emacs-bug and provide the exact details for
reproducing the bug, preferably starting with `emacs -Q'.
> Is there any way to globally turn off continuous syntax checking
> for all modes ?
Try putting
(global-font-lock-mode -1)
in your .emacs.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: emacs coding modes need 'Suspend Disbelief' button
2017-05-19 10:54 emacs coding modes need 'Suspend Disbelief' button Jason Vas Dias
2017-05-19 11:20 ` tomas
2017-05-19 11:42 ` Óscar Fuentes
@ 2017-05-19 11:45 ` hector
2017-05-19 13:35 ` Drew Adams
2017-05-19 16:23 ` Stefan Monnier
4 siblings, 0 replies; 8+ messages in thread
From: hector @ 2017-05-19 11:45 UTC (permalink / raw)
To: help-gnu-emacs
On Fri, May 19, 2017 at 10:54:28AM +0000, Jason Vas Dias wrote:
> The insistence of modern emacs on always unconditionally
> syntax checking everything greatly slows down typing and
> is a major inhibition to quick editing of large source files .
Maybe disabling fontification is enough. You can do it for large
buffers with "font-lock-maximum-size".
Or setting the variable "font-lock-maximum-decoration".
I'm not sure whether this would disable parsing.
^ permalink raw reply [flat|nested] 8+ messages in thread
* RE: emacs coding modes need 'Suspend Disbelief' button
2017-05-19 10:54 emacs coding modes need 'Suspend Disbelief' button Jason Vas Dias
` (2 preceding siblings ...)
2017-05-19 11:45 ` hector
@ 2017-05-19 13:35 ` Drew Adams
2017-05-19 16:23 ` Stefan Monnier
4 siblings, 0 replies; 8+ messages in thread
From: Drew Adams @ 2017-05-19 13:35 UTC (permalink / raw)
To: Jason Vas Dias, emacs-devel, help-gnu-emacs
Please don't cross-post to emacs-devel and help-gnu-emacs.
Pick one.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: emacs coding modes need 'Suspend Disbelief' button
2017-05-19 10:54 emacs coding modes need 'Suspend Disbelief' button Jason Vas Dias
` (3 preceding siblings ...)
2017-05-19 13:35 ` Drew Adams
@ 2017-05-19 16:23 ` Stefan Monnier
4 siblings, 0 replies; 8+ messages in thread
From: Stefan Monnier @ 2017-05-19 16:23 UTC (permalink / raw)
To: help-gnu-emacs; +Cc: emacs-devel
> then, when I enter '"' or "'", the rest of the text
> would not be colored - this is really annoying and greatly
> slows down editing of large files -
Normally when you insert " only the current line gets "colored"
immediately, and the rest of the buffer is only re-"colored" by
jit-lock's contextual highlighting, i.e. after jit-lock-context-time of
idle time. So if keep Emacs busy enough until you hit the closing " the
rest of the buffer should not be re-"colored" incorrectly even temporarily.
This said, even if it is re-"colored", that shouldn't slow anything down
(IOW if there's a noticeable slowdown, please report it so we can try
and fix it).
> The insistence of modern emacs on always unconditionally
> syntax checking everything greatly slows down typing and
> is a major inhibition to quick editing of large source files.
IIUC you're bumping into some performance problems.
If so, please report them (with M-x report-emacs-bug and enough details
that we can try and reproduce them) so we can try to fix them.
> And in some modes, such as shell script mode, and also
> cc-mode, it is still possible to core-dump Emacs (latest 25.2 version)
Core dumps are serious bugs, so please M-x report-emacs-bug.
We try pretty hard to fix those promptly.
If they're difficult to reproduce, the best is for you to run Emacs
within GDB and then send us the output of "bt" when it crashes.
> I have core-dumped emacs several times recently by doing this -
> one example that works pretty reliably is to start defining a
> function within a function in shell-script - there is a timing
> related bug , if you don't enter the opening '{' fast enough,
> emacs will core-dump .
My best guess here is that maybe your system has a stack-space limit
that's lower than what Emacs expects for some reason, so that the code
we have to try and check that we don't overflow the stack (e.g. in the
regexp matcher) doesn't do its job.
Stefan
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2017-05-20 7:47 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-05-19 10:54 emacs coding modes need 'Suspend Disbelief' button Jason Vas Dias
2017-05-19 11:20 ` tomas
[not found] ` <CALyZvKzvUBe1-+yTnpK97MA=Dh5q89RmTugG3CJ0bcrbqnd2Eg@mail.gmail.com>
2017-05-19 11:37 ` Fwd: " Jason Vas Dias
2017-05-20 7:47 ` Robert Thorpe
2017-05-19 11:42 ` Óscar Fuentes
2017-05-19 11:45 ` hector
2017-05-19 13:35 ` Drew Adams
2017-05-19 16:23 ` Stefan Monnier
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).