Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit1c54b93

Browse files
committed
Avoid using non-ASCII commentary in daitch_mokotoff.c.
Commitd6b5dee failed to suppress that warning from MSVC,so let's just get rid of all non-ASCII glyphs in the comments.The comment for iso8859_1_to_ascii_upper[] is not essential,and the other cases can be handled by spelling out theUnicode character names.(I'm now really in the dark as to why MSVC doesn't complainabout predicate.c's comment. But whatever.)Discussion:https://postgr.es/m/1546512.1681495035@sss.pgh.pa.us
1 parente9f451a commit1c54b93

File tree

1 file changed

+9
-15
lines changed

1 file changed

+9
-15
lines changed

‎contrib/fuzzystrmatch/daitch_mokotoff.c‎

Lines changed: 9 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -111,9 +111,6 @@ static const dm_codes end_codes[2] =
111111

112112
/* Mapping from ISO8859-1 to upper-case ASCII, covering the range 0x60..0xFF. */
113113
staticconstchariso8859_1_to_ascii_upper[]=
114-
/*
115-
"`abcdefghijklmnopqrstuvwxyz{|}~ ¡.....various odd symbols.....¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖ*ØÙÚÛÜÝÞßàáâãäåæçèéêëìíîïðñòóôõö/øùúûüýþÿ"
116-
*/
117114
"`ABCDEFGHIJKLMNOPQRSTUVWXYZ{|}~ ! ?AAAAAAECEEEEIIIIDNOOOOO*OUUUUYDSAAAAAAECEEEEIIIIDNOOOOO/OUUUUYDY";
118115

119116
/* Internal C implementation */
@@ -413,7 +410,7 @@ read_char(const unsigned char *str, int *ix)
413410
/* Convert. */
414411
if (c >= (unsignedchar)'['&&c <= (unsignedchar)']')
415412
{
416-
/* ASCII characters [, \, and ] are reserved forĄ, Ę, and Ţ/Ț. */
413+
/* ASCII characters [, \, and ] are reserved forconversions below. */
417414
returnna;
418415
}
419416
elseif (c<0x60)
@@ -431,19 +428,16 @@ read_char(const unsigned char *str, int *ix)
431428
/* Conversion of non-ASCII characters in the coding chart. */
432429
switch (c)
433430
{
434-
case0x0104:
435-
case0x0105:
436-
/* Ą/ą */
431+
case0x0104:/* LATIN CAPITAL LETTER A WITH OGONEK */
432+
case0x0105:/* LATIN SMALL LETTER A WITH OGONEK */
437433
return'[';
438-
case0x0118:
439-
case0x0119:
440-
/* Ę/ę */
434+
case0x0118:/* LATIN CAPITAL LETTER E WITH OGONEK */
435+
case0x0119:/* LATIN SMALL LETTER E WITH OGONEK */
441436
return'\\';
442-
case0x0162:
443-
case0x0163:
444-
case0x021A:
445-
case0x021B:
446-
/* Ţ/ţ or Ț/ț */
437+
case0x0162:/* LATIN CAPITAL LETTER T WITH CEDILLA */
438+
case0x0163:/* LATIN SMALL LETTER T WITH CEDILLA */
439+
case0x021A:/* LATIN CAPITAL LETTER T WITH COMMA BELOW */
440+
case0x021B:/* LATIN SMALL LETTER T WITH COMMA BELOW */
447441
return']';
448442
default:
449443
returnna;

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp