Closed wezm closed 11 months ago
I submitted a different fix as helix-editor/helix#8953.
Note that there are no cases for Unicode where the above definition of isascii is incorrect. There are very few other encodings that don't meet this, and we don't support any of them. (E.g. EBCDIC or SHIFT-JIS.) All the Latin-X versions for example meet this criteria.
I'm closing this in favor of #22 which fixes the same bug.
Cool, happy to have a fix either way.
When building with gcc or clang passing
-std=c11
scanner.c fails to build (helix builds grammars with this argument):gcc:
clang:
It seems that
isascii
is deprecated and is not visible by default with-std=c11
. This PR attempts to address that although I'm not 100% sure it's the right fix. A better option might be to defineisascii
in this project if it's not already defined. Open to suggestions