help-gnu-emacs
[Top][All Lists]
Advanced

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

Pressing enter sometimes starts giving "wrong type argument: stringp, ni


From: Evan Driscoll
Subject: Pressing enter sometimes starts giving "wrong type argument: stringp, nil"
Date: Wed, 29 Jul 2015 18:43:51 -0500

Occasionally emacs will start producing an error when I press enter,
displaying "wrong type argument: stringp, nil" in the minibuffer and
not moving the point down a line. It still actually inserts the
newline though. In other words, what I get is something like the
following. If I have the following document where <> is the location
of the point:

    abc<>
    def

and press enter, what I get is

    abc<>

    def

which gets really annoying.


If I toggle-debug-on-error, it gives me this stack trace:

    Debugger entered--Lisp error: (wrong-type-argument stringp nil)
      looking-at(nil)
      c-forward-sws()
      c-mask-paragraph(nil t do-auto-fill)
      c-do-auto-fill()
      self-insert-command(1)
      newline(nil)
      call-interactively(newline nil nil)

This seems to happen in all modes (or at least several different
modes, including fundamental) and I don't really know what is likely
to trigger it. Sometimes I can close the buffer and reopen it and the
problem goes away; sometimes it seems to "infect" other buffers and I
have to restart emacs.

I have tried starting emacs with the --no-init-file option. It didn't
do it for a little while, but I got annoyed at a few missing settings
so went and executed some selected expressions in it to set up mostly
some c-mode setup. Nothing I did stands out to me like anything too
unusual.

Anyone have any ideas what I can look at to try to figure out what's
causing it, or how to fix it?

Evan



reply via email to

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