X-Git-Url: https://git.tld-linux.org/?p=packages%2Fcoreutils.git;a=blobdiff_plain;f=coreutils-fmt-wchars.patch;fp=coreutils-fmt-wchars.patch;h=fcc6792efc939af08132e7dd19466d97580b19a1;hp=e82dde10be6df065855969cbf15af929e17ea2c1;hb=e804a1edb9dcd75e9f4f8f5abe5d4fe3ce254fed;hpb=3ee41a31401b18dfbb372217470a5ee39b4aac37 diff --git a/coreutils-fmt-wchars.patch b/coreutils-fmt-wchars.patch index e82dde1..fcc6792 100644 --- a/coreutils-fmt-wchars.patch +++ b/coreutils-fmt-wchars.patch @@ -83,13 +83,13 @@ + /* Extra ctype(3)-style macros. */ --#define isopen(c) (strchr ("(['`\"", c) != NULL) --#define isclose(c) (strchr (")]'\"", c) != NULL) --#define isperiod(c) (strchr (".?!", c) != NULL) +-#define isopen(c) (strchr ("(['`\"", c) != nullptr) +-#define isclose(c) (strchr (")]'\"", c) != nullptr) +-#define isperiod(c) (strchr (".?!", c) != nullptr) +#define isopen(c) \ -+ (wcschr (L"(['`\"\u2018\u201A\u201B\u201C\u201E\u201F", c) != NULL) -+#define isclose(c) (wcschr (L")]'\"\u2018\u2019\u201C\u201D", c) != NULL) -+#define isperiod(c) (wcschr (L".?!", c) != NULL) ++ (wcschr (L"(['`\"\u2018\u201A\u201B\u201C\u201E\u201F", c) != nullptr) ++#define isclose(c) (wcschr (L")]'\"\u2018\u2019\u201C\u201D", c) != nullptr) ++#define isperiod(c) (wcschr (L".?!", c) != nullptr) /* Size of a tab stop, for expansion on input and re-introduction on output. */ @@ -214,12 +214,12 @@ -g, --goal=WIDTH goal width (default of 93% of width)\n\ "), stdout); @@ -311,6 +336,7 @@ - {"split-only", no_argument, NULL, 's'}, - {"tagged-paragraph", no_argument, NULL, 't'}, - {"uniform-spacing", no_argument, NULL, 'u'}, -+ {"single-spaces", no_argument, NULL, 'n'}, - {"width", required_argument, NULL, 'w'}, - {"goal", required_argument, NULL, 'g'}, + {"split-only", no_argument, nullptr, 's'}, + {"tagged-paragraph", no_argument, nullptr, 't'}, + {"uniform-spacing", no_argument, nullptr, 'u'}, ++ {"single-spaces", no_argument, nullptr, 'n'}, + {"width", required_argument, nullptr, 'w'}, + {"goal", required_argument, nullptr, 'g'}, {GETOPT_HELP_OPTION_DECL}, @@ -335,9 +361,10 @@ atexit (close_stdout); @@ -240,7 +240,7 @@ - while ((optchar = getopt_long (argc, argv, "0123456789cstuw:p:g:", + while ((optchar = getopt_long (argc, argv, "0123456789cstunw:p:g:", - long_options, NULL)) + long_options, nullptr)) != -1) switch (optchar) @@ -378,6 +405,10 @@ @@ -611,7 +611,7 @@ + word_limit->width = saved_width; } - /* Return the constant component of the cost of breaking before the + /* Work around . */ @@ -932,33 +975,33 @@ else if ((this - 1)->punct) cost -= PUNCT_BONUS;