all: remove use of 'register' keyword

We should have done this a decade ago...

https://bugzilla.gnome.org/show_bug.cgi?id=730293
This commit is contained in:
Ryan Lortie 2014-05-25 12:18:14 +02:00 committed by Matthias Clasen
parent d217429729
commit dce88768dc
18 changed files with 168 additions and 171 deletions

View File

@ -235,10 +235,10 @@ static void
completion_check_cache (GCompletion* cmp,
gchar** new_prefix)
{
register GList* list;
register gsize len;
register gsize i;
register gsize plen;
GList* list;
gsize len;
gsize i;
gsize plen;
gchar* postfix;
gchar* s;

View File

@ -233,7 +233,7 @@ static void
md5_transform (guint32 buf[4],
guint32 const in[16])
{
register guint32 a, b, c, d;
guint32 a, b, c, d;
/* The four core functions - F1 is optimized somewhat */
#define F1(x, y, z) (z ^ (x & (y ^ z)))

View File

@ -281,7 +281,7 @@ g_datalist_clear (GData **datalist)
static inline GDataset*
g_dataset_lookup (gconstpointer dataset_location)
{
register GDataset *dataset;
GDataset *dataset;
if (g_dataset_cached && g_dataset_cached->location == dataset_location)
return g_dataset_cached;
@ -297,7 +297,7 @@ g_dataset_lookup (gconstpointer dataset_location)
static void
g_dataset_destroy_internal (GDataset *dataset)
{
register gconstpointer dataset_location;
gconstpointer dataset_location;
dataset_location = dataset->location;
while (dataset)
@ -331,7 +331,7 @@ g_dataset_destroy (gconstpointer dataset_location)
G_LOCK (g_dataset_global);
if (g_dataset_location_ht)
{
register GDataset *dataset;
GDataset *dataset;
dataset = g_dataset_lookup (dataset_location);
if (dataset)
@ -552,7 +552,7 @@ g_dataset_id_set_data_full (gconstpointer dataset_location,
gpointer data,
GDestroyNotify destroy_func)
{
register GDataset *dataset;
GDataset *dataset;
g_return_if_fail (dataset_location != NULL);
if (!data)
@ -1070,7 +1070,7 @@ g_dataset_foreach (gconstpointer dataset_location,
GDataForeachFunc func,
gpointer user_data)
{
register GDataset *dataset;
GDataset *dataset;
g_return_if_fail (dataset_location != NULL);
g_return_if_fail (func != NULL);

View File

@ -363,7 +363,7 @@ write_string (int fd,
static GLogDomain*
g_log_find_domain_L (const gchar *log_domain)
{
register GLogDomain *domain;
GLogDomain *domain;
domain = g_log_domains;
while (domain)
@ -378,7 +378,7 @@ g_log_find_domain_L (const gchar *log_domain)
static GLogDomain*
g_log_domain_new_L (const gchar *log_domain)
{
register GLogDomain *domain;
GLogDomain *domain;
domain = g_new (GLogDomain, 1);
domain->log_domain = g_strdup (log_domain);
@ -397,7 +397,7 @@ g_log_domain_check_free_L (GLogDomain *domain)
if (domain->fatal_mask == G_LOG_FATAL_MASK &&
domain->handlers == NULL)
{
register GLogDomain *last, *work;
GLogDomain *last, *work;
last = NULL;
@ -427,7 +427,7 @@ g_log_domain_get_handler_L (GLogDomain *domain,
{
if (domain && log_level)
{
register GLogHandler *handler;
GLogHandler *handler;
handler = domain->handlers;
while (handler)
@ -498,7 +498,7 @@ g_log_set_fatal_mask (const gchar *log_domain,
GLogLevelFlags fatal_mask)
{
GLogLevelFlags old_flags;
register GLogDomain *domain;
GLogDomain *domain;
if (!log_domain)
log_domain = "";
@ -674,7 +674,7 @@ void
g_log_remove_handler (const gchar *log_domain,
guint handler_id)
{
register GLogDomain *domain;
GLogDomain *domain;
g_return_if_fail (handler_id > 0);
@ -980,7 +980,7 @@ g_logv (const gchar *log_domain,
for (i = g_bit_nth_msf (log_level, -1); i >= 0; i = g_bit_nth_msf (log_level, i))
{
register GLogLevelFlags test_level;
GLogLevelFlags test_level;
test_level = 1 << i;
if (log_level & test_level)

View File

@ -83,8 +83,8 @@ g_pattern_ph_match (const gchar *match_pattern,
const gchar *match_string,
gboolean *wildcard_reached_p)
{
register const gchar *pattern, *string;
register gchar ch;
const gchar *pattern, *string;
gchar ch;
pattern = match_pattern;
string = match_string;

View File

@ -469,8 +469,8 @@ g_stpcpy (gchar *dest,
g_return_val_if_fail (src != NULL, NULL);
return stpcpy (dest, src);
#else
register gchar *d = dest;
register const gchar *s = src;
gchar *d = dest;
const gchar *s = src;
g_return_val_if_fail (dest != NULL, NULL);
g_return_val_if_fail (src != NULL, NULL);
@ -1348,9 +1348,9 @@ g_strlcpy (gchar *dest,
const gchar *src,
gsize dest_size)
{
register gchar *d = dest;
register const gchar *s = src;
register gsize n = dest_size;
gchar *d = dest;
const gchar *s = src;
gsize n = dest_size;
g_return_val_if_fail (dest != NULL, 0);
g_return_val_if_fail (src != NULL, 0);
@ -1359,7 +1359,7 @@ g_strlcpy (gchar *dest,
if (n != 0 && --n != 0)
do
{
register gchar c = *s++;
gchar c = *s++;
*d++ = c;
if (c == 0)
@ -1409,9 +1409,9 @@ g_strlcat (gchar *dest,
const gchar *src,
gsize dest_size)
{
register gchar *d = dest;
register const gchar *s = src;
register gsize bytes_left = dest_size;
gchar *d = dest;
const gchar *s = src;
gsize bytes_left = dest_size;
gsize dlength; /* Logically, MIN (strlen (d), dest_size) */
g_return_val_if_fail (dest != NULL, 0);
@ -1539,7 +1539,7 @@ g_str_is_ascii (const gchar *str)
gchar*
g_strdown (gchar *string)
{
register guchar *s;
guchar *s;
g_return_val_if_fail (string != NULL, NULL);
@ -1570,7 +1570,7 @@ g_strdown (gchar *string)
gchar*
g_strup (gchar *string)
{
register guchar *s;
guchar *s;
g_return_val_if_fail (string != NULL, NULL);
@ -1606,14 +1606,14 @@ g_strreverse (gchar *string)
if (*string)
{
register gchar *h, *t;
gchar *h, *t;
h = string;
t = string + strlen (string) - 1;
while (h < t)
{
register gchar c;
gchar c;
c = *h;
*h = *t;
@ -1934,7 +1934,7 @@ g_strdelimit (gchar *string,
const gchar *delimiters,
gchar new_delim)
{
register gchar *c;
gchar *c;
g_return_val_if_fail (string != NULL, NULL);
@ -1971,7 +1971,7 @@ g_strcanon (gchar *string,
const gchar *valid_chars,
gchar substitutor)
{
register gchar *c;
gchar *c;
g_return_val_if_fail (string != NULL, NULL);
g_return_val_if_fail (valid_chars != NULL, NULL);

View File

@ -188,7 +188,7 @@ typedef const gchar * (*GTranslateFunc) (const gchar *str,
# if defined (__i386__)
# define GUINT16_SWAP_LE_BE_IA32(val) \
(G_GNUC_EXTENSION \
({ register guint16 __v, __x = ((guint16) (val)); \
({ guint16 __v, __x = ((guint16) (val)); \
if (__builtin_constant_p (__x)) \
__v = GUINT16_SWAP_LE_BE_CONSTANT (__x); \
else \
@ -202,7 +202,7 @@ typedef const gchar * (*GTranslateFunc) (const gchar *str,
&& !defined (__pentiumpro__) && !defined (__pentium4__)
# define GUINT32_SWAP_LE_BE_IA32(val) \
(G_GNUC_EXTENSION \
({ register guint32 __v, __x = ((guint32) (val)); \
({ guint32 __v, __x = ((guint32) (val)); \
if (__builtin_constant_p (__x)) \
__v = GUINT32_SWAP_LE_BE_CONSTANT (__x); \
else \
@ -216,7 +216,7 @@ typedef const gchar * (*GTranslateFunc) (const gchar *str,
# else /* 486 and higher has bswap */
# define GUINT32_SWAP_LE_BE_IA32(val) \
(G_GNUC_EXTENSION \
({ register guint32 __v, __x = ((guint32) (val)); \
({ guint32 __v, __x = ((guint32) (val)); \
if (__builtin_constant_p (__x)) \
__v = GUINT32_SWAP_LE_BE_CONSTANT (__x); \
else \
@ -249,7 +249,7 @@ typedef const gchar * (*GTranslateFunc) (const gchar *str,
# elif defined (__ia64__)
# define GUINT16_SWAP_LE_BE_IA64(val) \
(G_GNUC_EXTENSION \
({ register guint16 __v, __x = ((guint16) (val)); \
({ guint16 __v, __x = ((guint16) (val)); \
if (__builtin_constant_p (__x)) \
__v = GUINT16_SWAP_LE_BE_CONSTANT (__x); \
else \
@ -260,7 +260,7 @@ typedef const gchar * (*GTranslateFunc) (const gchar *str,
__v; }))
# define GUINT32_SWAP_LE_BE_IA64(val) \
(G_GNUC_EXTENSION \
({ register guint32 __v, __x = ((guint32) (val)); \
({ guint32 __v, __x = ((guint32) (val)); \
if (__builtin_constant_p (__x)) \
__v = GUINT32_SWAP_LE_BE_CONSTANT (__x); \
else \
@ -271,7 +271,7 @@ typedef const gchar * (*GTranslateFunc) (const gchar *str,
__v; }))
# define GUINT64_SWAP_LE_BE_IA64(val) \
(G_GNUC_EXTENSION \
({ register guint64 __v, __x = ((guint64) (val)); \
({ guint64 __v, __x = ((guint64) (val)); \
if (__builtin_constant_p (__x)) \
__v = GUINT64_SWAP_LE_BE_CONSTANT (__x); \
else \
@ -289,7 +289,7 @@ typedef const gchar * (*GTranslateFunc) (const gchar *str,
# elif defined (__x86_64__)
# define GUINT32_SWAP_LE_BE_X86_64(val) \
(G_GNUC_EXTENSION \
({ register guint32 __v, __x = ((guint32) (val)); \
({ guint32 __v, __x = ((guint32) (val)); \
if (__builtin_constant_p (__x)) \
__v = GUINT32_SWAP_LE_BE_CONSTANT (__x); \
else \
@ -299,7 +299,7 @@ typedef const gchar * (*GTranslateFunc) (const gchar *str,
__v; }))
# define GUINT64_SWAP_LE_BE_X86_64(val) \
(G_GNUC_EXTENSION \
({ register guint64 __v, __x = ((guint64) (val)); \
({ guint64 __v, __x = ((guint64) (val)); \
if (__builtin_constant_p (__x)) \
__v = GUINT64_SWAP_LE_BE_CONSTANT (__x); \
else \

View File

@ -307,7 +307,7 @@ g_bit_storage (gulong number)
return G_LIKELY (number) ?
((GLIB_SIZEOF_LONG * 8U - 1) ^ (guint) __builtin_clzl(number)) + 1 : 1;
#else
register guint n_bits = 0;
guint n_bits = 0;
do
{

View File

@ -829,7 +829,7 @@ else
c = 0;
for (i = 0; i < 4; ++i)
{
register int cc = *(++ptr);
int cc = *(++ptr);
#ifndef EBCDIC /* ASCII/UTF-8 coding */
if (cc >= CHAR_a) cc -= 32; /* Convert to upper case */
c = (c << 4) + cc - ((cc < CHAR_A)? CHAR_0 : (CHAR_A - 10));
@ -1039,7 +1039,7 @@ else
c = 0;
for (i = 0; i < 2; ++i)
{
register int cc = *(++ptr);
int cc = *(++ptr);
#ifndef EBCDIC /* ASCII/UTF-8 coding */
if (cc >= CHAR_a) cc -= 32; /* Convert to upper case */
c = (c << 4) + cc - ((cc < CHAR_A)? CHAR_0 : (CHAR_A - 10));
@ -1059,7 +1059,7 @@ else
c = 0;
while (MAX_255(*pt) && g_ascii_isxdigit(*pt) != 0)
{
register int cc = *pt++;
int cc = *pt++;
if (c == 0 && cc == CHAR_0) continue; /* Leading zeroes */
#ifndef EBCDIC /* ASCII/UTF-8 coding */
@ -1721,8 +1721,8 @@ find_fixedlength(pcre_uchar *code, BOOL utf, BOOL atend, compile_data *cd)
{
int length = -1;
register int branchlength = 0;
register pcre_uchar *cc = code + 1 + LINK_SIZE;
int branchlength = 0;
pcre_uchar *cc = code + 1 + LINK_SIZE;
/* Scan along the opcodes for this branch. If we get to the end of the
branch, check the length against that of the other branches. */
@ -1731,7 +1731,7 @@ for (;;)
{
int d;
pcre_uchar *ce, *cs;
register int op = *cc;
int op = *cc;
switch (op)
{
@ -2045,7 +2045,7 @@ PRIV(find_bracket)(const pcre_uchar *code, BOOL utf, int number)
{
for (;;)
{
register int c = *code;
int c = *code;
if (c == OP_END) return NULL;
@ -2183,7 +2183,7 @@ find_recurse(const pcre_uchar *code, BOOL utf)
{
for (;;)
{
register int c = *code;
int c = *code;
if (c == OP_END) return NULL;
if (c == OP_RECURSE) return code;
@ -2337,7 +2337,7 @@ static BOOL
could_be_empty_branch(const pcre_uchar *code, const pcre_uchar *endcode,
BOOL utf, compile_data *cd)
{
register int c;
int c;
for (code = first_significant_code(code + PRIV(OP_lengths)[*code], TRUE);
code < endcode;
code = first_significant_code(code + PRIV(OP_lengths)[c], TRUE))
@ -2737,7 +2737,7 @@ static int
check_posix_name(const pcre_uchar *ptr, int len)
{
const char *pn = posix_names;
register int yield = 0;
int yield = 0;
while (posix_name_lengths[yield] != 0)
{
if (len == posix_name_lengths[yield] &&
@ -3449,8 +3449,8 @@ pcre_int32 req_caseopt, reqvary, tempreqvary;
int options = *optionsptr; /* May change dynamically */
int after_manual_callout = 0;
int length_prevgroup = 0;
register int c;
register pcre_uchar *code = *codeptr;
int c;
pcre_uchar *code = *codeptr;
pcre_uchar *last_code = code;
pcre_uchar *orig_code = code;
pcre_uchar *tempcode;
@ -3896,7 +3896,7 @@ for (;; ptr++)
{
BOOL local_negate = FALSE;
int posix_class, taboffset, tabopt;
register const pcre_uint8 *cbits = cd->cbits;
const pcre_uint8 *cbits = cd->cbits;
pcre_uint8 pbits[32];
if (ptr[1] != CHAR_COLON)
@ -4023,7 +4023,7 @@ for (;; ptr++)
if (c < 0)
{
register const pcre_uint8 *cbits = cd->cbits;
const pcre_uint8 *cbits = cd->cbits;
/* Every class contains at least two < 256 characters. */
class_has_8bitchar++;
/* Every class contains at least two characters. */
@ -5111,7 +5111,7 @@ for (;; ptr++)
else if (*previous >= OP_ASSERT && *previous <= OP_COND)
{
register int i;
int i;
int len = (int)(code - previous);
pcre_uchar *bralink = NULL;
pcre_uchar *brazeroptr = NULL;
@ -7340,13 +7340,13 @@ Returns: TRUE or FALSE
*/
static BOOL
is_anchored(register const pcre_uchar *code, unsigned int bracket_map,
is_anchored(const pcre_uchar *code, unsigned int bracket_map,
unsigned int backref_map)
{
do {
const pcre_uchar *scode = first_significant_code(
code + PRIV(OP_lengths)[*code], FALSE);
register int op = *scode;
int op = *scode;
/* Non-capturing brackets */
@ -7423,7 +7423,7 @@ is_startline(const pcre_uchar *code, unsigned int bracket_map,
do {
const pcre_uchar *scode = first_significant_code(
code + PRIV(OP_lengths)[*code], FALSE);
register int op = *scode;
int op = *scode;
/* If we are at the start of a conditional assertion group, *both* the
conditional assertion *and* what follows the condition must satisfy the test
@ -7522,14 +7522,14 @@ Returns: -1 or the fixed first char
static int
find_firstassertedchar(const pcre_uchar *code, BOOL inassert)
{
register int c = -1;
int c = -1;
do {
int d;
int xl = (*code == OP_CBRA || *code == OP_SCBRA ||
*code == OP_CBRAPOS || *code == OP_SCBRAPOS)? IMM2_SIZE:0;
const pcre_uchar *scode = first_significant_code(code + 1+LINK_SIZE + xl,
TRUE);
register int op = *scode;
int op = *scode;
switch(op)
{

View File

@ -3464,7 +3464,7 @@ for (;;)
{
while (current_subject < end_subject)
{
register unsigned int c = *current_subject;
unsigned int c = *current_subject;
#ifndef COMPILE_PCRE8
if (c > 255) c = 255;
#endif
@ -3519,7 +3519,7 @@ for (;;)
if (has_req_char && end_subject - current_subject < REQ_BYTE_MAX)
{
register PCRE_PUCHAR p = current_subject + (has_first_char? 1:0);
PCRE_PUCHAR p = current_subject + (has_first_char? 1:0);
/* We don't need to repeat the search if we haven't yet reached the
place we found it at last time. */
@ -3530,7 +3530,7 @@ for (;;)
{
while (p < end_subject)
{
register int pp = *p++;
int pp = *p++;
if (pp == req_char || pp == req_char2) { p--; break; }
}
}

View File

@ -145,11 +145,11 @@ Returns: >= 0 the number of subject bytes matched
*/
static int
match_ref(int offset, register PCRE_PUCHAR eptr, int length, match_data *md,
match_ref(int offset, PCRE_PUCHAR eptr, int length, match_data *md,
BOOL caseless)
{
PCRE_PUCHAR eptr_start = eptr;
register PCRE_PUCHAR p = md->start_subject + md->offset_vector[offset];
PCRE_PUCHAR p = md->start_subject + md->offset_vector[offset];
#ifdef PCRE_DEBUG
if (eptr >= md->end_subject)
@ -285,7 +285,6 @@ versions and production versions. Note that the "rw" argument of RMATCH isn't
actually used in this definition. */
#ifndef NO_RECURSE
#define REGISTER register
#ifdef PCRE_DEBUG
#define RMATCH(ra,rb,rc,rd,re,rw) \
@ -312,8 +311,6 @@ actually used in this definition. */
the "rd" argument of RMATCH isn't actually used in this definition. It's the md
argument of match(), which never changes. */
#define REGISTER
#define RMATCH(ra,rb,rc,rd,re,rw)\
{\
heapframe *newframe = frame->Xnextframe;\
@ -478,7 +475,7 @@ Returns: MATCH_MATCH if matched ) these values are >= 0
*/
static int
match(REGISTER PCRE_PUCHAR eptr, REGISTER const pcre_uchar *ecode,
match(PCRE_PUCHAR eptr, const pcre_uchar *ecode,
PCRE_PUCHAR mstart, int offset_top, match_data *md, eptrblock *eptrb,
unsigned int rdepth)
{
@ -486,10 +483,10 @@ match(REGISTER PCRE_PUCHAR eptr, REGISTER const pcre_uchar *ecode,
so they can be ordinary variables in all cases. Mark some of them with
"register" because they are used a lot in loops. */
register int rrc; /* Returns from recursive calls */
register int i; /* Used for loops not involving calls to RMATCH() */
register unsigned int c; /* Character values not kept over RMATCH() calls */
register BOOL utf; /* Local copy of UTF flag for speed */
int rrc; /* Returns from recursive calls */
int i; /* Used for loops not involving calls to RMATCH() */
unsigned int c; /* Character values not kept over RMATCH() calls */
BOOL utf; /* Local copy of UTF flag for speed */
BOOL minimize, possessive; /* Quantifier options */
BOOL caseless;
@ -1942,8 +1939,8 @@ for (;;)
if (offset > offset_top)
{
register int *iptr = md->offset_vector + offset_top;
register int *iend = md->offset_vector + offset;
int *iptr = md->offset_vector + offset_top;
int *iend = md->offset_vector + offset;
while (iptr < iend) *iptr++ = -1;
}
@ -3575,7 +3572,7 @@ for (;;)
#ifdef SUPPORT_UTF
if (utf)
{
register unsigned int ch, och;
unsigned int ch, och;
ecode++;
GETCHARINC(ch, ecode);
@ -3602,7 +3599,7 @@ for (;;)
else
#endif
{
register unsigned int ch = ecode[1];
unsigned int ch = ecode[1];
c = *eptr++;
if (ch == c || (op == OP_NOTI && TABLE_GET(ch, md->fcc, ch) == c))
RRETURN(MATCH_NOMATCH);
@ -3716,7 +3713,7 @@ for (;;)
#ifdef SUPPORT_UTF
if (utf)
{
register unsigned int d;
unsigned int d;
for (i = 1; i <= min; i++)
{
if (eptr >= md->end_subject)
@ -3751,7 +3748,7 @@ for (;;)
#ifdef SUPPORT_UTF
if (utf)
{
register unsigned int d;
unsigned int d;
for (fi = min;; fi++)
{
RMATCH(eptr, ecode, offset_top, md, eptrb, RM28);
@ -3796,7 +3793,7 @@ for (;;)
#ifdef SUPPORT_UTF
if (utf)
{
register unsigned int d;
unsigned int d;
for (i = min; i < max; i++)
{
int len = 1;
@ -3853,7 +3850,7 @@ for (;;)
#ifdef SUPPORT_UTF
if (utf)
{
register unsigned int d;
unsigned int d;
for (i = 1; i <= min; i++)
{
if (eptr >= md->end_subject)
@ -3887,7 +3884,7 @@ for (;;)
#ifdef SUPPORT_UTF
if (utf)
{
register unsigned int d;
unsigned int d;
for (fi = min;; fi++)
{
RMATCH(eptr, ecode, offset_top, md, eptrb, RM32);
@ -3931,7 +3928,7 @@ for (;;)
#ifdef SUPPORT_UTF
if (utf)
{
register unsigned int d;
unsigned int d;
for (i = min; i < max; i++)
{
int len = 1;
@ -6497,7 +6494,7 @@ tables = re->tables;
if (extra_data != NULL)
{
register unsigned int flags = extra_data->flags;
unsigned int flags = extra_data->flags;
if ((flags & PCRE_EXTRA_STUDY_DATA) != 0)
study = (const pcre_study_data *)extra_data->study_data;
if ((flags & PCRE_EXTRA_MATCH_LIMIT) != 0)
@ -6658,8 +6655,8 @@ in case they inspect these fields. */
if (md->offset_vector != NULL)
{
register int *iptr = md->offset_vector + ocount;
register int *iend = iptr - re->top_bracket;
int *iptr = md->offset_vector + ocount;
int *iend = iptr - re->top_bracket;
if (iend < md->offset_vector + 2) iend = md->offset_vector + 2;
while (--iptr >= iend) *iptr = -1;
md->offset_vector[0] = md->offset_vector[1] = -1;
@ -6804,7 +6801,7 @@ for(;;)
{
while (start_match < end_subject)
{
register unsigned int c = *start_match;
unsigned int c = *start_match;
#ifndef COMPILE_PCRE8
if (c > 255) c = 255;
#endif
@ -6861,7 +6858,7 @@ for(;;)
if (has_req_char && end_subject - start_match < REQ_BYTE_MAX)
{
register PCRE_PUCHAR p = start_match + (has_first_char? 1:0);
PCRE_PUCHAR p = start_match + (has_first_char? 1:0);
/* We don't need to repeat the search if we haven't yet reached the
place we found it at last time. */
@ -6872,7 +6869,7 @@ for(;;)
{
while (p < end_subject)
{
register int pp = *p++;
int pp = *p++;
if (pp == req_char || pp == req_char2) { p--; break; }
}
}
@ -7065,7 +7062,7 @@ if (rc == MATCH_MATCH || rc == MATCH_ACCEPT)
if (md->end_offset_top/2 <= re->top_bracket && offsets != NULL)
{
register int *iptr, *iend;
int *iptr, *iend;
int resetcount = 2 + re->top_bracket * 2;
if (resetcount > offsetcount) resetcount = offsetcount;
iptr = offsets + md->end_offset_top;

View File

@ -67,7 +67,7 @@ PRIV(ord2utf)(pcre_uint32 cvalue, pcre_uchar *buffer)
{
#ifdef SUPPORT_UTF
register int i, j;
int i, j;
/* Checking invalid cvalue character, encoded as invalid UTF-16 character.
Should never happen in practice. */

View File

@ -85,8 +85,8 @@ int length = -1;
/* PCRE_UTF16 has the same value as PCRE_UTF8. */
BOOL utf = (options & PCRE_UTF8) != 0;
BOOL had_recurse = FALSE;
register int branchlength = 0;
register pcre_uchar *cc = (pcre_uchar *)code + 1 + LINK_SIZE;
int branchlength = 0;
pcre_uchar *cc = (pcre_uchar *)code + 1 + LINK_SIZE;
if (*code == OP_CBRA || *code == OP_SCBRA ||
*code == OP_CBRAPOS || *code == OP_SCBRAPOS) cc += IMM2_SIZE;
@ -98,7 +98,7 @@ for (;;)
{
int d, min;
pcre_uchar *cs, *ce;
register int op = *cc;
int op = *cc;
switch (op)
{
@ -631,7 +631,7 @@ static void
set_type_bits(pcre_uint8 *start_bits, int cbit_type, int table_limit,
compile_data *cd)
{
register int c;
int c;
for (c = 0; c < table_limit; c++) start_bits[c] |= cd->cbits[c+cbit_type];
#if defined SUPPORT_UTF && defined COMPILE_PCRE8
if (table_limit == 32) return;
@ -673,7 +673,7 @@ static void
set_nottype_bits(pcre_uint8 *start_bits, int cbit_type, int table_limit,
compile_data *cd)
{
register int c;
int c;
for (c = 0; c < table_limit; c++) start_bits[c] |= ~cd->cbits[c+cbit_type];
#if defined SUPPORT_UTF && defined COMPILE_PCRE8
if (table_limit != 32) for (c = 24; c < 32; c++) start_bits[c] = 0xff;
@ -710,7 +710,7 @@ static int
set_start_bits(const pcre_uchar *code, pcre_uint8 *start_bits, BOOL utf,
compile_data *cd)
{
register int c;
int c;
int yield = SSB_DONE;
#if defined SUPPORT_UTF && defined COMPILE_PCRE8
int table_limit = utf? 16:32;

View File

@ -106,7 +106,7 @@ int
PRIV(valid_utf)(PCRE_PUCHAR string, int length, int *erroroffset)
{
#ifdef SUPPORT_UTF
register PCRE_PUCHAR p;
PCRE_PUCHAR p;
if (length < 0)
{
@ -116,7 +116,7 @@ if (length < 0)
for (p = string; length-- > 0; p++)
{
register int ab, c, d;
int ab, c, d;
c = *p;
if (c < 128) continue; /* ASCII character */

View File

@ -64,9 +64,9 @@ g_cclosure_marshal_VOID__VOID (GClosure *closure,
{
typedef void (*GMarshalFunc_VOID__VOID) (gpointer data1,
gpointer data2);
register GMarshalFunc_VOID__VOID callback;
register GCClosure *cc = (GCClosure*) closure;
register gpointer data1, data2;
GMarshalFunc_VOID__VOID callback;
GCClosure *cc = (GCClosure*) closure;
gpointer data1, data2;
g_return_if_fail (n_param_values == 1);
@ -129,9 +129,9 @@ g_cclosure_marshal_VOID__BOOLEAN (GClosure *closure,
typedef void (*GMarshalFunc_VOID__BOOLEAN) (gpointer data1,
gboolean arg_1,
gpointer data2);
register GMarshalFunc_VOID__BOOLEAN callback;
register GCClosure *cc = (GCClosure*) closure;
register gpointer data1, data2;
GMarshalFunc_VOID__BOOLEAN callback;
GCClosure *cc = (GCClosure*) closure;
gpointer data1, data2;
g_return_if_fail (n_param_values == 2);
@ -203,9 +203,9 @@ g_cclosure_marshal_VOID__CHAR (GClosure *closure,
typedef void (*GMarshalFunc_VOID__CHAR) (gpointer data1,
gchar arg_1,
gpointer data2);
register GMarshalFunc_VOID__CHAR callback;
register GCClosure *cc = (GCClosure*) closure;
register gpointer data1, data2;
GMarshalFunc_VOID__CHAR callback;
GCClosure *cc = (GCClosure*) closure;
gpointer data1, data2;
g_return_if_fail (n_param_values == 2);
@ -277,9 +277,9 @@ g_cclosure_marshal_VOID__UCHAR (GClosure *closure,
typedef void (*GMarshalFunc_VOID__UCHAR) (gpointer data1,
guchar arg_1,
gpointer data2);
register GMarshalFunc_VOID__UCHAR callback;
register GCClosure *cc = (GCClosure*) closure;
register gpointer data1, data2;
GMarshalFunc_VOID__UCHAR callback;
GCClosure *cc = (GCClosure*) closure;
gpointer data1, data2;
g_return_if_fail (n_param_values == 2);
@ -351,9 +351,9 @@ g_cclosure_marshal_VOID__INT (GClosure *closure,
typedef void (*GMarshalFunc_VOID__INT) (gpointer data1,
gint arg_1,
gpointer data2);
register GMarshalFunc_VOID__INT callback;
register GCClosure *cc = (GCClosure*) closure;
register gpointer data1, data2;
GMarshalFunc_VOID__INT callback;
GCClosure *cc = (GCClosure*) closure;
gpointer data1, data2;
g_return_if_fail (n_param_values == 2);
@ -425,9 +425,9 @@ g_cclosure_marshal_VOID__UINT (GClosure *closure,
typedef void (*GMarshalFunc_VOID__UINT) (gpointer data1,
guint arg_1,
gpointer data2);
register GMarshalFunc_VOID__UINT callback;
register GCClosure *cc = (GCClosure*) closure;
register gpointer data1, data2;
GMarshalFunc_VOID__UINT callback;
GCClosure *cc = (GCClosure*) closure;
gpointer data1, data2;
g_return_if_fail (n_param_values == 2);
@ -499,9 +499,9 @@ g_cclosure_marshal_VOID__LONG (GClosure *closure,
typedef void (*GMarshalFunc_VOID__LONG) (gpointer data1,
glong arg_1,
gpointer data2);
register GMarshalFunc_VOID__LONG callback;
register GCClosure *cc = (GCClosure*) closure;
register gpointer data1, data2;
GMarshalFunc_VOID__LONG callback;
GCClosure *cc = (GCClosure*) closure;
gpointer data1, data2;
g_return_if_fail (n_param_values == 2);
@ -573,9 +573,9 @@ g_cclosure_marshal_VOID__ULONG (GClosure *closure,
typedef void (*GMarshalFunc_VOID__ULONG) (gpointer data1,
gulong arg_1,
gpointer data2);
register GMarshalFunc_VOID__ULONG callback;
register GCClosure *cc = (GCClosure*) closure;
register gpointer data1, data2;
GMarshalFunc_VOID__ULONG callback;
GCClosure *cc = (GCClosure*) closure;
gpointer data1, data2;
g_return_if_fail (n_param_values == 2);
@ -647,9 +647,9 @@ g_cclosure_marshal_VOID__ENUM (GClosure *closure,
typedef void (*GMarshalFunc_VOID__ENUM) (gpointer data1,
gint arg_1,
gpointer data2);
register GMarshalFunc_VOID__ENUM callback;
register GCClosure *cc = (GCClosure*) closure;
register gpointer data1, data2;
GMarshalFunc_VOID__ENUM callback;
GCClosure *cc = (GCClosure*) closure;
gpointer data1, data2;
g_return_if_fail (n_param_values == 2);
@ -721,9 +721,9 @@ g_cclosure_marshal_VOID__FLAGS (GClosure *closure,
typedef void (*GMarshalFunc_VOID__FLAGS) (gpointer data1,
guint arg_1,
gpointer data2);
register GMarshalFunc_VOID__FLAGS callback;
register GCClosure *cc = (GCClosure*) closure;
register gpointer data1, data2;
GMarshalFunc_VOID__FLAGS callback;
GCClosure *cc = (GCClosure*) closure;
gpointer data1, data2;
g_return_if_fail (n_param_values == 2);
@ -795,9 +795,9 @@ g_cclosure_marshal_VOID__FLOAT (GClosure *closure,
typedef void (*GMarshalFunc_VOID__FLOAT) (gpointer data1,
gfloat arg_1,
gpointer data2);
register GMarshalFunc_VOID__FLOAT callback;
register GCClosure *cc = (GCClosure*) closure;
register gpointer data1, data2;
GMarshalFunc_VOID__FLOAT callback;
GCClosure *cc = (GCClosure*) closure;
gpointer data1, data2;
g_return_if_fail (n_param_values == 2);
@ -869,9 +869,9 @@ g_cclosure_marshal_VOID__DOUBLE (GClosure *closure,
typedef void (*GMarshalFunc_VOID__DOUBLE) (gpointer data1,
gdouble arg_1,
gpointer data2);
register GMarshalFunc_VOID__DOUBLE callback;
register GCClosure *cc = (GCClosure*) closure;
register gpointer data1, data2;
GMarshalFunc_VOID__DOUBLE callback;
GCClosure *cc = (GCClosure*) closure;
gpointer data1, data2;
g_return_if_fail (n_param_values == 2);
@ -943,9 +943,9 @@ g_cclosure_marshal_VOID__STRING (GClosure *closure,
typedef void (*GMarshalFunc_VOID__STRING) (gpointer data1,
gpointer arg_1,
gpointer data2);
register GMarshalFunc_VOID__STRING callback;
register GCClosure *cc = (GCClosure*) closure;
register gpointer data1, data2;
GMarshalFunc_VOID__STRING callback;
GCClosure *cc = (GCClosure*) closure;
gpointer data1, data2;
g_return_if_fail (n_param_values == 2);
@ -1021,9 +1021,9 @@ g_cclosure_marshal_VOID__PARAM (GClosure *closure,
typedef void (*GMarshalFunc_VOID__PARAM) (gpointer data1,
gpointer arg_1,
gpointer data2);
register GMarshalFunc_VOID__PARAM callback;
register GCClosure *cc = (GCClosure*) closure;
register gpointer data1, data2;
GMarshalFunc_VOID__PARAM callback;
GCClosure *cc = (GCClosure*) closure;
gpointer data1, data2;
g_return_if_fail (n_param_values == 2);
@ -1099,9 +1099,9 @@ g_cclosure_marshal_VOID__BOXED (GClosure *closure,
typedef void (*GMarshalFunc_VOID__BOXED) (gpointer data1,
gpointer arg_1,
gpointer data2);
register GMarshalFunc_VOID__BOXED callback;
register GCClosure *cc = (GCClosure*) closure;
register gpointer data1, data2;
GMarshalFunc_VOID__BOXED callback;
GCClosure *cc = (GCClosure*) closure;
gpointer data1, data2;
g_return_if_fail (n_param_values == 2);
@ -1177,9 +1177,9 @@ g_cclosure_marshal_VOID__POINTER (GClosure *closure,
typedef void (*GMarshalFunc_VOID__POINTER) (gpointer data1,
gpointer arg_1,
gpointer data2);
register GMarshalFunc_VOID__POINTER callback;
register GCClosure *cc = (GCClosure*) closure;
register gpointer data1, data2;
GMarshalFunc_VOID__POINTER callback;
GCClosure *cc = (GCClosure*) closure;
gpointer data1, data2;
g_return_if_fail (n_param_values == 2);
@ -1251,9 +1251,9 @@ g_cclosure_marshal_VOID__OBJECT (GClosure *closure,
typedef void (*GMarshalFunc_VOID__OBJECT) (gpointer data1,
gpointer arg_1,
gpointer data2);
register GMarshalFunc_VOID__OBJECT callback;
register GCClosure *cc = (GCClosure*) closure;
register gpointer data1, data2;
GMarshalFunc_VOID__OBJECT callback;
GCClosure *cc = (GCClosure*) closure;
gpointer data1, data2;
g_return_if_fail (n_param_values == 2);
@ -1329,9 +1329,9 @@ g_cclosure_marshal_VOID__VARIANT (GClosure *closure,
typedef void (*GMarshalFunc_VOID__VARIANT) (gpointer data1,
gpointer arg_1,
gpointer data2);
register GMarshalFunc_VOID__VARIANT callback;
register GCClosure *cc = (GCClosure*) closure;
register gpointer data1, data2;
GMarshalFunc_VOID__VARIANT callback;
GCClosure *cc = (GCClosure*) closure;
gpointer data1, data2;
g_return_if_fail (n_param_values == 2);
@ -1408,9 +1408,9 @@ g_cclosure_marshal_VOID__UINT_POINTER (GClosure *closure,
guint arg_1,
gpointer arg_2,
gpointer data2);
register GMarshalFunc_VOID__UINT_POINTER callback;
register GCClosure *cc = (GCClosure*) closure;
register gpointer data1, data2;
GMarshalFunc_VOID__UINT_POINTER callback;
GCClosure *cc = (GCClosure*) closure;
gpointer data1, data2;
g_return_if_fail (n_param_values == 3);
@ -1487,9 +1487,9 @@ g_cclosure_marshal_BOOLEAN__FLAGS (GClosure *closure,
typedef gboolean (*GMarshalFunc_BOOLEAN__FLAGS) (gpointer data1,
guint arg_1,
gpointer data2);
register GMarshalFunc_BOOLEAN__FLAGS callback;
register GCClosure *cc = (GCClosure*) closure;
register gpointer data1, data2;
GMarshalFunc_BOOLEAN__FLAGS callback;
GCClosure *cc = (GCClosure*) closure;
gpointer data1, data2;
gboolean v_return;
g_return_if_fail (return_value != NULL);
@ -1571,9 +1571,9 @@ g_cclosure_marshal_STRING__OBJECT_POINTER (GClosure *closure,
gpointer arg_1,
gpointer arg_2,
gpointer data2);
register GMarshalFunc_STRING__OBJECT_POINTER callback;
register GCClosure *cc = (GCClosure*) closure;
register gpointer data1, data2;
GMarshalFunc_STRING__OBJECT_POINTER callback;
GCClosure *cc = (GCClosure*) closure;
gpointer data1, data2;
gchar* v_return;
g_return_if_fail (return_value != NULL);
@ -1664,9 +1664,9 @@ g_cclosure_marshal_BOOLEAN__BOXED_BOXED (GClosure *closure,
gpointer arg_1,
gpointer arg_2,
gpointer data2);
register GMarshalFunc_BOOLEAN__BOXED_BOXED callback;
register GCClosure *cc = (GCClosure*) closure;
register gpointer data1, data2;
GMarshalFunc_BOOLEAN__BOXED_BOXED callback;
GCClosure *cc = (GCClosure*) closure;
gpointer data1, data2;
gboolean v_return;
g_return_if_fail (return_value != NULL);

View File

@ -302,7 +302,7 @@ static guint g_n_signal_nodes = 0;
static SignalNode **g_signal_nodes = NULL;
static inline SignalNode*
LOOKUP_SIGNAL_NODE (register guint signal_id)
LOOKUP_SIGNAL_NODE (guint signal_id)
{
if (signal_id < g_n_signal_nodes)
return g_signal_nodes[signal_id];

View File

@ -386,7 +386,7 @@ static TypeNode *static_fundamental_type_nodes[(G_TYPE_FUNDAMENTAL_MAX >> G_TYP
static GType static_fundamental_next = G_TYPE_RESERVED_USER_FIRST;
static inline TypeNode*
lookup_type_node_I (register GType utype)
lookup_type_node_I (GType utype)
{
if (utype > G_TYPE_FUNDAMENTAL_MAX)
return (TypeNode*) (utype & ~TYPE_ID_MASK);

View File

@ -81,7 +81,7 @@ naive_bit_nth_msf (gulong mask, gint nth_bit)
static guint
naive_bit_storage (gulong number)
{
register guint n_bits = 0;
guint n_bits = 0;
do
{