1
1

justify: extend the quoting regex, to cover more types of comments

Now also comment blocks in Fortran, Lisp, Lua, Postgres, and TeX
can be rewrapped with ^J.

This partially addresses https://savannah.gnu.org/bugs/?55435.
Kind-of-requested-by: David Griffith <dave@661.org>
Этот коммит содержится в:
Benno Schulenberg 2019-01-22 17:50:34 +01:00
родитель da4b7e430f
Коммит c5a72103bf

Просмотреть файл

@ -2468,7 +2468,7 @@ int main(int argc, char **argv)
if (brackets == NULL)
brackets = mallocstrcpy(NULL, "\"')>]}");
if (quotestr == NULL)
quotestr = mallocstrcpy(NULL, "^([ \t]*([#:>|}]|/{2}))+");
quotestr = mallocstrcpy(NULL, "^([ \t]*([!#%:;>|}]|/{2}|--))+");
/* Compile the quoting regex, and exit when it's invalid. */
quoterc = regcomp(&quotereg, quotestr, NANO_REG_EXTENDED);