xC: describe general.editor parse errors
This commit is contained in:
parent
93b66b6a26
commit
80089a4d65
19
xC.c
19
xC.c
@ -13887,22 +13887,27 @@ build_editor_command (struct app_context *ctx, const char *filename)
|
|||||||
{
|
{
|
||||||
case 'F':
|
case 'F':
|
||||||
str_append (&argument, filename);
|
str_append (&argument, filename);
|
||||||
break;
|
continue;
|
||||||
case 'L':
|
case 'L':
|
||||||
str_append_printf (&argument, "%zu", line_one_based);
|
str_append_printf (&argument, "%zu", line_one_based);
|
||||||
break;
|
continue;
|
||||||
case 'C':
|
case 'C':
|
||||||
str_append_printf (&argument, "%zu", column + 1);
|
str_append_printf (&argument, "%zu", column + 1);
|
||||||
break;
|
continue;
|
||||||
case 'B':
|
case 'B':
|
||||||
str_append_printf (&argument, "%d", cursor + 1);
|
str_append_printf (&argument, "%d", cursor + 1);
|
||||||
break;
|
continue;
|
||||||
case '%':
|
case '%':
|
||||||
case ' ':
|
case ' ':
|
||||||
str_append_c (&argument, *editor);
|
str_append_c (&argument, *editor);
|
||||||
break;
|
continue;
|
||||||
default:
|
}
|
||||||
print_warning ("unknown substitution variable");
|
|
||||||
|
const char *p = editor;
|
||||||
|
if (soft_assert (utf8_decode (&p, strlen (p)) > 0))
|
||||||
|
{
|
||||||
|
log_global_error (ctx, "Unknown substitution variable: %#&s",
|
||||||
|
xstrndup (editor, p - editor));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (argument.len)
|
if (argument.len)
|
||||||
|
Loading…
Reference in New Issue
Block a user