Fix for wrong syntax highlighting in the face of tokenizer errors, e.g.

"echo 'hi"
This commit is contained in:
ridiculousfish
2014-01-03 17:42:25 -08:00
parent c8eec109b2
commit bf75731bbe
2 changed files with 12 additions and 2 deletions

View File

@@ -2638,8 +2638,15 @@ static void test_highlighting(void)
{NULL, -1}
};
const highlight_component_t components10[] =
{
{L"echo", HIGHLIGHT_COMMAND},
{L"'single_quote", HIGHLIGHT_ERROR},
{NULL, -1}
};
const highlight_component_t *tests[] = {components1, components2, components3, components4, components5, components6, components7, components8, components9};
const highlight_component_t *tests[] = {components1, components2, components3, components4, components5, components6, components7, components8, components9, components10};
for (size_t which = 0; which < sizeof tests / sizeof *tests; which++)
{
const highlight_component_t *components = tests[which];