>From 4a81b73bc97b01ea9619e517809997397213f0dc Mon Sep 17 00:00:00 2001 From: Theodor Thornhill Date: Mon, 21 Nov 2022 12:14:07 +0100 Subject: [PATCH] Fix some font-lock-settings * lisp/progmodes/c-ts-mode.el (c-ts-mode--font-lock-settings): Remove expression_statement and fix typo for the c-ts-mode--fontify-declarator font lock helper function. --- lisp/progmodes/c-ts-mode.el | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/lisp/progmodes/c-ts-mode.el b/lisp/progmodes/c-ts-mode.el index 6ba209c0fb..17f27611a5 100644 --- a/lisp/progmodes/c-ts-mode.el +++ b/lisp/progmodes/c-ts-mode.el @@ -263,19 +263,19 @@ c-ts-mode--font-lock-settings declarator: (_) @font-lock-variable-name-face) (field_declaration - declarator: (_) @c-ts-mode--fontify-struct-declarator) + declarator: (_) @c-ts-mode--fontify-declarator) (function_definition - declarator: (_) @c-ts-mode--fontify-struct-declarator)) + declarator: (_) @c-ts-mode--fontify-declarator)) ;; Should we highlight identifiers in the parameter list? ;; (parameter_declaration - ;; declarator: (_) @c-ts-mode--fontify-struct-declarator)) + ;; declarator: (_) @c-ts-mode--fontify-declarator)) :language mode :feature 'assignment ;; TODO: Recursively highlight identifiers in parenthesized - ;; expressions, see `c-ts-mode--fontify-struct-declarator' for + ;; expressions, see `c-ts-mode--fontify-declarator' for ;; inspiration. '((assignment_expression left: (identifier) @font-lock-variable-name-face) @@ -299,8 +299,7 @@ c-ts-mode--font-lock-settings :language mode :feature 'label - '((expression_statement (identifier) @font-lock-variable-name-face) - (labeled_statement + '((labeled_statement label: (statement_identifier) @font-lock-constant-face)) :language mode -- 2.34.1