diff options
| author | orbitalquark <70453897+orbitalquark@users.noreply.github.com> | 2024-09-18 13:14:18 -0400 |
|---|---|---|
| committer | Randy Palamar <randy@rnpnr.xyz> | 2025-01-04 12:22:04 -0700 |
| commit | a916f1cf4291da3ba4ffc55df6427497b4006f93 (patch) | |
| tree | 3591f51e7291c1db2ebd215b0dd27c62ec27f5b5 /lua/lexers/makefile.lua | |
| parent | b9fb1c6c4ce27fa101f455a530d4c35c73581975 (diff) | |
| download | vis-a916f1cf4291da3ba4ffc55df6427497b4006f93.tar.gz vis-a916f1cf4291da3ba4ffc55df6427497b4006f93.tar.xz | |
Allow unfinished Makefile function definitions to be highlighted
Diffstat (limited to 'lua/lexers/makefile.lua')
| -rw-r--r-- | lua/lexers/makefile.lua | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lua/lexers/makefile.lua b/lua/lexers/makefile.lua index fd90ba2..3e7ae8b 100644 --- a/lua/lexers/makefile.lua +++ b/lua/lexers/makefile.lua @@ -11,8 +11,8 @@ local word = (lexer.any - lexer.space - S('$:,#=(){}'))^1 local func_name = lex:tag(lexer.FUNCTION, word) local ws = lex:get_rule('whitespace') local eq = lex:tag(lexer.OPERATOR, '=') -lex:add_rule('function_def', - lex:tag(lexer.KEYWORD, lexer.word_match('define')) * ws * func_name * ws^-1 * eq) +lex:add_rule('function_def', lex:tag(lexer.KEYWORD, lexer.word_match('define')) * ws * func_name * + ws^-1 * (eq + -1)) -- Keywords. lex:add_rule('keyword', lex:tag(lexer.KEYWORD, P('!')^-1 * lex:word_match(lexer.KEYWORD, true))) |
