diff options
| author | orbitalquark <70453897+orbitalquark@users.noreply.github.com> | 2024-12-22 23:22:36 -0500 |
|---|---|---|
| committer | Randy Palamar <randy@rnpnr.xyz> | 2025-01-04 12:36:40 -0700 |
| commit | 1b7cfb25a28000a930c89cef369d49e0e3eda792 (patch) | |
| tree | 56028c76e752e299668883f9772075ba4180e744 | |
| parent | 0dfa1163620dc08c9853bfc47a455381b82828f1 (diff) | |
| download | vis-1b7cfb25a28000a930c89cef369d49e0e3eda792.tar.gz vis-1b7cfb25a28000a930c89cef369d49e0e3eda792.tar.xz | |
Recognize float suffixes in C lexer
| -rw-r--r-- | lua/lexers/c.lua | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lua/lexers/c.lua b/lua/lexers/c.lua index eacae09..627334d 100644 --- a/lua/lexers/c.lua +++ b/lua/lexers/c.lua @@ -43,7 +43,7 @@ lex:add_rule('comment', lex:tag(lexer.COMMENT, line_comment + block_comment)) -- Numbers. local integer = lexer.integer * lexer.word_match('u l ll ul ull lu llu', true)^-1 -local float = lexer.float * P('f')^-1 +local float = lexer.float * lexer.word_match('f l df dd dl i j', true)^-1 lex:add_rule('number', lex:tag(lexer.NUMBER, float + integer)) -- Preprocessor. |
