In UTF-8 locales, the ranges A-F and a-f include several accented
characters beyond "ABCDEF" and "abcdef", such as the Croat č and ć.
This fixes https://savannah.gnu.org/bugs/?61487.
Bug existed since the beginning of each of the syntaxes,
for the C syntax since version 1.3.6, commit 159bdfdc.
In many places a carriage return is not valid whitespace and should
thus not be colored as such. In some of these places a vertical tab
or form feed is maybe valid whitespace, but it would be ugly or even
wrong to color them because they are not part of the subsequent
comment or keyword.
This fixes https://savannah.gnu.org/bugs/?60456.
Also, don't partially color "..." as an operator, because it isn't,
and color also the unary operator "#".
Signed-off-by: Mark-Weston <markweston@cock.li>
The list now includes all the Lua 5.3 functions listed on
https://www.lua.org/manual/5.3/#index.
Also, remove the coloring of just the library name, so that
only known library functions get highlighted.
Signed-off-by: Tom Levy <tomlevy93@gmail.com>
Since a "0x" by itself is invalid. Also add word boundaries, so that
e.g. "00x1" (which is invalid) does not get partial highlighting.
Also remove some redundant backslashes from the strings regex.
Signed-off-by: Tom Levy <tomlevy93@gmail.com>
Functions such as "io.close" should only be highlighted when the
package name ("io") is a word by itself, otherwise code such as
"fooio.close" gets unexpected partial highlighting.
Signed-off-by: Tom Levy <tomlevy93@gmail.com>
Since file-5.10 (end of 2011), libmagic identifies a C file in most
cases as "C source" instead of as "C program". Nano's magic strings
for some other files didn't match any more what file-5.32 currently
produces, either. So, they have been adjusted, new ones added, and
old ones deleted.
This fixes https://savannah.gnu.org/bugs/?52445.