summaryrefslogtreecommitdiff
path: root/extra/locale
diff options
context:
space:
mode:
authorBernhard Reutner-Fischer <rep.dot.nop@gmail.com>2008-07-23 11:23:36 +0000
committerBernhard Reutner-Fischer <rep.dot.nop@gmail.com>2008-07-23 11:23:36 +0000
commit1f020b178664857b0e107778d04fb971a58e6230 (patch)
treec1cd86593b5d354091e0fa3201c5789bec5c53ad /extra/locale
parentf1775381f91f1250b20f1949dfd0364ddb0ee9fc (diff)
- trim any trailing whitespace
Diffstat (limited to 'extra/locale')
-rw-r--r--extra/locale/gen_collate.c36
-rw-r--r--extra/locale/gen_ldc.c4
-rw-r--r--extra/locale/gen_locale.c8
-rw-r--r--extra/locale/gen_wc8bit.c4
-rw-r--r--extra/locale/gen_wctype.c6
5 files changed, 29 insertions, 29 deletions
diff --git a/extra/locale/gen_collate.c b/extra/locale/gen_collate.c
index 42b20f79a..77dc5ff9e 100644
--- a/extra/locale/gen_collate.c
+++ b/extra/locale/gen_collate.c
@@ -62,7 +62,7 @@ typedef struct {
int base_idx; /* */
int undefined_idx; /* */
-
+
int overrides_offset; /* */
int multistart_offset; /* */
} der_locale_t;
@@ -1094,7 +1094,7 @@ int main(int argc, char **argv)
return EXIT_FAILURE;
}
- init_locale_list();
+ init_locale_list();
while (--argc) {
p = (const deps_t *) bsearch(*++argv, deps, sizeof(deps)/sizeof(deps[0]), sizeof(deps[0]), dep_cmp);
@@ -1107,7 +1107,7 @@ int main(int argc, char **argv)
return EXIT_FAILURE;
}
}
-
+
i = p->base_locale;
++der_count[i];
@@ -1115,7 +1115,7 @@ int main(int argc, char **argv)
/* same name as base, so skip after count incremented */
continue;
}
-
+
/* add it to the list. the main body will catch duplicates */
lli = (ll_item_t *) xmalloc(sizeof(ll_item_t));
lli->prev = lli->next = NULL;
@@ -1202,7 +1202,7 @@ static int old_main(int argc, char **argv)
processfile(); /* this does a popfile */
/* twalk(cur_col->root_colitem, print_colnode); */
-
+
if (next_is_base == 1) {
next_is_base = 0;
}
@@ -1264,7 +1264,7 @@ static int old_main(int argc, char **argv)
return EXIT_SUCCESS;
}
-static void error_msg(const char *fmt, ...)
+static void error_msg(const char *fmt, ...)
{
va_list arg;
@@ -1289,7 +1289,7 @@ static void pushfile(char *filename)
if (fno >= MAX_FNO) {
error_msg("file stack size exceeded");
}
-
+
if (!(fstack[++fno] = fopen(fbuf, "r"))) {
--fno; /* oops */
error_msg("cannot open file %s", fbuf);
@@ -1645,7 +1645,7 @@ static int colelement_cmp(const void *n1, const void *n2)
r = 0; /* both null */
} else {
r = (((colitem_t *)n1)->element == NULL) ? -1 : 1;
- }
+ }
}
return r;
}
@@ -1733,7 +1733,7 @@ static void add_script(const char *s)
if (find_section_list_item(s, cur_col)) {
error_msg("attempt to readd script %s", s);
}
-
+
l = find_ll_last(cur_col->section_list);
insque(new_ll_item(DT_SECTION, new_section(s)), l);
}
@@ -2674,7 +2674,7 @@ static void finalize_base(void)
index2weight_buffer[index2weight_len] = lli->idx = i++;
index2weight_len += index2weight_len_inc;
add_final_col_index(w->symbol);
-
+
} else {
assert(lli->data_type & DT_REORDER);
r = ll_len( ((section_t *)(lli->data))->itm_list );
@@ -2975,7 +2975,7 @@ static void finalize_base(void)
continue;
}
if (index2weight_len_inc) {
- index2ruleidx_buffer[index2ruleidx_len++] =
+ index2ruleidx_buffer[index2ruleidx_len++] =
add_rule((weighted_item_t *)(lli->data));
}
/* fprintf(stdout, "%11s: w %6d %6d %s\n", */
@@ -3001,7 +3001,7 @@ static void finalize_base(void)
w = (weighted_item_t *)(lli->data);
if (find_wi_index_reordered(w->symbol)) { /* reordered symbol so skip on first pass */
if (index2weight_len_inc) {
- index2ruleidx_buffer[index2ruleidx_len++] =
+ index2ruleidx_buffer[index2ruleidx_len++] =
add_rule((weighted_item_t *)(lli->data));
}
/* fprintf(stdout, "%11s: r %6d %6d %s\n", */
@@ -3050,7 +3050,7 @@ static void finalize_base(void)
der_locale_array[der_locale_len].name = cur_base->name;
der_locale_array[der_locale_len].base_idx = base_locale_len;
-
+
u16_buf[0] = 1;
u16_buf[1] = 0;
u16_buf_len = 2;
@@ -3511,7 +3511,7 @@ size_t newopt(tbl_item *ut, size_t usize, int shift, table_data *tbl)
/* sort */
nu_val = blocksize;
qsort(ti, numblocks, sizeof(unsigned char *), nu_memcmp);
-
+
uniq = 1;
uit[(ti[0]-ut)/blocksize] = 0;
for (i=1 ; i < numblocks ; i++) {
@@ -3687,7 +3687,7 @@ static unsigned int add_rule(weighted_item_t *wi)
assert(r < (1 << 14));
rbuf[i] = r | rule2val[(int)(w->rule[i])];
} else { /* item */
- r = final_index_val_x(w->colitem[i], wi->symbol);
+ r = final_index_val_x(w->colitem[i], wi->symbol);
rbuf[i] = r | rule2val[(int)(w->rule[i])];
}
}
@@ -3831,7 +3831,7 @@ static void dump_der_locale(int n)
DUMPn(base_idx);
DUMPn(undefined_idx);
-
+
DUMPn(overrides_offset);
DUMPn(multistart_offset);
@@ -3856,7 +3856,7 @@ static void dump_u16_array(FILE *fp, uint16_t *u, int len, const char *name)
collate_pos += len;
}
-#define OUT_U16C(X,N) fprintf(fp,"\t%10d, /* %8lu %s */\n", X, collate_pos++, N);
+#define OUT_U16C(X,N) fprintf(fp,"\t%10d, /* %8lu %s */\n", X, collate_pos++, N);
static void dump_collate(FILE *fp)
{
@@ -3901,7 +3901,7 @@ static void dump_collate(FILE *fp)
DUMPn(wcs2colidt_offset_low);
DUMPn(wcs2colidt_offset_hi);
}
-#undef DUMPn
+#undef DUMPn
fprintf(fp, "#define COL_IDX_C %5d\n", 0);
diff --git a/extra/locale/gen_ldc.c b/extra/locale/gen_ldc.c
index 3ffc90efe..2a121610e 100644
--- a/extra/locale/gen_ldc.c
+++ b/extra/locale/gen_ldc.c
@@ -238,7 +238,7 @@ int main(void)
/* collate should be last*/
assert(sizeof(__locale_collate_tbl)/sizeof(__locale_collate_tbl[0]) == __lc_collate_data_LEN) ;
out_u16(lso, __locale_collate_tbl, __lc_collate_data_LEN, "collate_data");
-
+
{
unsigned char co_buf[__LOCALE_DATA_CATEGORIES] = {
@@ -251,7 +251,7 @@ int main(void)
};
out_uc(lso, co_buf, __LOCALE_DATA_CATEGORIES, "lc_common_item_offsets_LEN");
}
-
+
out_size_t(lso, common_tbl_offsets, __LOCALE_DATA_CATEGORIES * 4, "lc_common_tbl_offsets");
/* offsets from start of locale_mmap_t */
/* rows, item_offsets, item_idx, data */
diff --git a/extra/locale/gen_locale.c b/extra/locale/gen_locale.c
index b44be318e..31df4156e 100644
--- a/extra/locale/gen_locale.c
+++ b/extra/locale/gen_locale.c
@@ -281,12 +281,12 @@ static void read_at_mappings(void)
#if 0
{
p = at_strings;
-
+
if (!*p) {
printf("no @ strings\n");
return;
}
-
+
do {
printf("%s\n", p+1);
p += 1 + (unsigned char) *p;
@@ -469,7 +469,7 @@ static void read_locale_list(void)
printf("ignoring UTF-8 locale %s\n", ln);
*line_buf = 0;
continue;
- } else if ((i > 2) && !default_8bit) {
+ } else if ((i > 2) && !default_8bit) {
printf("ignoring 8-bit codeset locale %s\n", ln);
*line_buf = 0;
continue;
@@ -503,7 +503,7 @@ static void read_locale_list(void)
printf("ignoring UTF-8 locale %s\n", ln);
*line_buf = 0;
continue;
- } else if ((i > 2) && !default_8bit) {
+ } else if ((i > 2) && !default_8bit) {
printf("ignoring 8-bit codeset locale %s\n", ln);
*line_buf = 0;
continue;
diff --git a/extra/locale/gen_wc8bit.c b/extra/locale/gen_wc8bit.c
index 3cdcca801..c6db41231 100644
--- a/extra/locale/gen_wc8bit.c
+++ b/extra/locale/gen_wc8bit.c
@@ -182,7 +182,7 @@ int main(int argc, char **argv)
char *s0;
char *s1;
int n;
-
+
s0 = strrchr(*argv, '/');
if (!s0) {
s0 = *argv;
@@ -379,7 +379,7 @@ int main(int argc, char **argv)
if ((c != 0) || 1) {
u = towupper(c);
l = towlower(c);
-
+
if (u >= 0x80) u = csd[numsets].w2c[u];
if (l >= 0x80) l = csd[numsets].w2c[l];
diff --git a/extra/locale/gen_wctype.c b/extra/locale/gen_wctype.c
index 2e2e42506..085ec51b1 100644
--- a/extra/locale/gen_wctype.c
+++ b/extra/locale/gen_wctype.c
@@ -709,7 +709,7 @@ int main(int argc, char **argv)
printf("%#8x : towupper glibc %#4x != %#4x mine\n",
c, towupper(c), upper);
}
-
+
if (towlower(c) != lower) {
printf("%#8x : towlower glibc %#4x != %#4x mine i0 = %d\n",
c, towlower(c), lower, i0);
@@ -739,7 +739,7 @@ int main(int argc, char **argv)
(unsigned long) RANGE);
output_table(fp, "ctype", &cttable);
output_table(fp, "uplow", &ultable);
-
+
#warning fix the upper bound on the upper/lower tables... save 200 bytes or so
fprintf(fp, "#define __LOCALE_DATA_WCuplow_diffs %7u\n", ul_count);
@@ -794,7 +794,7 @@ size_t newopt(unsigned char *ut, size_t usize, int shift, table_data *tbl)
/* sort */
nu_val = blocksize;
qsort(ti, numblocks, sizeof(unsigned char *), nu_memcmp);
-
+
uniq = 1;
uit[(ti[0]-ut)/blocksize] = 0;
for (i=1 ; i < numblocks ; i++) {