1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-05-07 13:53:19 -07:00
emacs/lisp/progmodes
Alan Mackenzie bb591f139f Enhance CC Mode's fontification, etc., of unterminated strings.
String delimiters, including escaped new lines, of correctly terminated
strings are left in font-lock-string-face.  All others get
font-lock-warning-face.  The latter get syntax-table text properties on the
opening string delim and the "terminating EOL".

Correct two miscellaneous bugs: the handling of text properties on Java Mode's
generic delimiters; the handling of c-just-done-before-change.

* lisp/progmodes/cc-defs.el (c-point): New position 'eoll "end of logical line".
(c-characterp): New macro.

* lisp/progmodes/cc-fonts.el (c-font-lock-invalid-string): Removed.
(c-basic-matchers-before): Use a simple matcher in place of the form around
c-font-lock-invalid-string.

* lisp/progmodes/cc-langs.el (c-get-state-before-change-functions): Add
c-before-change-check-unbalanced-strings to the value for all modes except AWK
Mode.  Also add c-before-change-check-<>-operators to Java Mode, correcting an
error in that mode's handling of generic delimiters.
(c-before-font-lock-functions): Add c-after-change-re-mark-unbalanced-strings
to the value for all modes except AWK Mode.
(c-single-quotes-quote-strings, c-string-delims): New lang variables for
future enhancements.
(c-string-innards-re-alist): New lang variable.

* lisp/progmodes/cc-mode.el (c-just-done-before-change): Do not set this
variable when a change is the alteration of text properties.
(c-basic-common-init): Set parse-sexp-lookup-properties (and the XEmacs
equivalent) also for Pike Mode.
(c-neutralize-CPP-line): No longer neutralize unbalanced quotes here.
(c-unescaped-nls-in-string-p, c-multiline-string-start-is-being-detached)
(c-pps-to-string-delim, c-before-change-check-unbalanced-strings)
(c-after-change-re-mark-unbalanced-strings): New functions.
(c-after-change): Fix a bug with the handling of c-just-done-before-change.
2018-05-20 13:28:14 +00:00
..
ada-mode.el * lisp/progmodes/ada-mode.el (ada-clean-buffer-before-saving): Doc fix. 2018-03-13 14:48:02 -04:00
ada-prj.el
ada-stmt.el ; Fix doc typos related to indefinite articles 2018-02-16 15:16:15 -05:00
ada-xref.el
antlr-mode.el Replace some uses of cl with cl-lib 2018-03-23 16:14:49 -04:00
asm-mode.el
autoconf.el
bat-mode.el Support variable-unquoting syntax in bat-mode 2018-03-15 15:23:01 +02:00
bug-reference.el
cc-align.el
cc-awk.el
cc-bytecomp.el
cc-cmds.el Fix some errors in c-display-defun-name when the type is "struct {..}", etc. 2018-01-28 17:53:07 +00:00
cc-defs.el Enhance CC Mode's fontification, etc., of unterminated strings. 2018-05-20 13:28:14 +00:00
cc-engine.el * lisp/progmodes/cc-{defs,engine,langs,vars}.el: Comment the use of "a\\`" 2018-04-02 19:53:41 +00:00
cc-fonts.el Enhance CC Mode's fontification, etc., of unterminated strings. 2018-05-20 13:28:14 +00:00
cc-guess.el
cc-langs.el Enhance CC Mode's fontification, etc., of unterminated strings. 2018-05-20 13:28:14 +00:00
cc-menus.el ; Fix doc typos related to indefinite articles 2018-02-16 15:16:15 -05:00
cc-mode.el Enhance CC Mode's fontification, etc., of unterminated strings. 2018-05-20 13:28:14 +00:00
cc-styles.el
cc-vars.el * lisp/progmodes/cc-{defs,engine,langs,vars}.el: Comment the use of "a\\`" 2018-04-02 19:53:41 +00:00
cfengine.el
cmacexp.el
compile.el Remove many items obsolete since Emacs 22.1 2018-03-10 19:15:56 -08:00
cperl-mode.el Remove many items obsolete since Emacs 22.1 2018-03-10 19:15:56 -08:00
cpp.el
cwarn.el
dcl-mode.el
ebnf-abn.el
ebnf-bnf.el
ebnf-dtd.el
ebnf-ebx.el
ebnf-iso.el
ebnf-otz.el
ebnf-yac.el
ebnf2ps.el
ebrowse.el Merge from origin/emacs-26 2018-03-28 09:38:22 -07:00
elisp-mode.el * lisp/progmodes/elisp-mode.el (eval-sexp-add-defvars): Don't macroexpand. 2018-02-18 13:02:29 -05:00
etags.el
executable.el
f90.el
flymake-proc.el Fix filesystem littering by Flymake's legacy backend 2018-05-11 23:29:05 +01:00
flymake.el Merge from origin/emacs-26 2018-03-04 17:16:39 -08:00
fortran.el
gdb-mi.el Quieten gud.el and gdb-mi.el compilation 2018-03-03 10:37:11 -08:00
glasses.el Replace uses of the obsolete local-write-file-hooks 2018-03-08 20:03:13 -05:00
grep.el Use next-error-found to set next-error-last-buffer. 2018-04-17 22:27:48 +03:00
gud.el Merge from origin/emacs-26 2018-05-07 07:50:49 -07:00
hideif.el
hideshow.el
icon.el ; Fix doc typos related to indefinite articles 2018-02-16 15:16:15 -05:00
idlw-complete-structtag.el
idlw-help.el Suppress some font-lock-fontify-buffer compiler warnings 2018-03-05 15:58:57 -05:00
idlw-shell.el Replace some uses of cl with cl-lib 2018-03-23 16:14:49 -04:00
idlw-toolbar.el Replace some uses of cl with cl-lib 2018-03-23 16:14:49 -04:00
idlwave.el Replace some uses of cl with cl-lib 2018-03-23 16:14:49 -04:00
inf-lisp.el ; Use GNU not Gnu in docs 2018-03-23 16:01:12 -04:00
js.el
ld-script.el
m4-mode.el
make-mode.el Give '$' punctuation syntax in make-mode (Bug#24477) 2018-05-15 19:33:34 -04:00
mantemp.el
meta-mode.el Stop mentioning options.el in doc 2018-03-12 21:09:36 -04:00
mixal-mode.el
modula2.el
octave.el The tedious game of whack-a-mole with compiler warnings continues 2018-04-20 18:34:39 -04:00
opascal.el
pascal.el Remove many items obsolete since Emacs 22.1 2018-03-10 19:15:56 -08:00
perl-mode.el Revert "Support all perl variable declarators and prefixes" 2018-03-20 20:14:40 -04:00
prog-mode.el
project.el
prolog.el
ps-mode.el
python.el run-python: Make the buffer running python current 2018-05-15 01:30:11 +09:00
ruby-mode.el Explicitly require cl-lib where needed 2018-03-16 20:41:17 -04:00
scheme.el
sh-script.el Merge from origin/emacs-26 2018-02-17 07:50:28 -08:00
simula.el
sql.el * lisp/progmodes/sql.el (comint-line-beginning-position): 2018-04-25 14:41:41 -04:00
subword.el
tcl.el
vera-mode.el
verilog-mode.el * lisp/progmodes/verilog-mode.el (verilog-mode): Quieten compilation. 2018-03-15 13:29:30 -04:00
vhdl-mode.el Replace uses of the obsolete local-write-file-hooks 2018-03-08 20:03:13 -05:00
which-func.el
xref.el Use next-error-found to set next-error-last-buffer. 2018-04-17 22:27:48 +03:00
xscheme.el