]> git.eshelyaron.com Git - emacs.git/commit
Fix syntax for < and > in c++-ts-mode (bug#60351)
authorYuan Fu <casouri@gmail.com>
Wed, 28 Dec 2022 23:44:26 +0000 (15:44 -0800)
committerYuan Fu <casouri@gmail.com>
Wed, 28 Dec 2022 23:44:26 +0000 (15:44 -0800)
commit19b8733aa27719e0aa60fad23a45a7f89d68b88d
treec04f461e1ce0c1c4bae06860b5d0a0d612c6f4e5
parentf509246ba12ac791291f586340622871cdfc18ed
Fix syntax for < and > in c++-ts-mode (bug#60351)

< and > are usually punctuation, e.g., in ->.  But when used for
templates, they should be considered pairs.  Right now we always
consider them as pairs which is incorrect.

* lisp/progmodes/c-ts-mode.el (c++-ts-mode--syntax-table): Remove
variable.
(c-ts-mode--syntax-propertize): New function.
(c++-ts-mode): Remove syntax table.  Setup syntax-propertize-function.
lisp/progmodes/c-ts-mode.el