From 5d8b924a625d2e4cfdb3452eeb8041eb80b3fee9 Mon Sep 17 00:00:00 2001 From: Michele Calgaro Date: Thu, 30 Jan 2020 20:17:40 +0900 Subject: [PATCH] Removed explicit usage of the 'register' keyword. Signed-off-by: Michele Calgaro --- kpat/freecell-solver/alloc.h | 6 +++--- kpat/freecell-solver/lookup2.c | 8 ++++---- kpat/freecell-solver/lookup2.h | 6 +++--- ksame/StoneField.cpp | 4 ++-- 4 files changed, 12 insertions(+), 12 deletions(-) diff --git a/kpat/freecell-solver/alloc.h b/kpat/freecell-solver/alloc.h index 5b339f24..c9c84078 100644 --- a/kpat/freecell-solver/alloc.h +++ b/kpat/freecell-solver/alloc.h @@ -35,7 +35,7 @@ extern char * #else #define fcs_compact_alloc_into_var(result,allocator_orig,what_t) \ { \ - register fcs_compact_allocator_t * allocator = (allocator_orig); \ + fcs_compact_allocator_t * allocator = (allocator_orig); \ if (allocator->max_ptr - allocator->ptr < sizeof(what_t)) \ { \ freecell_solver_compact_allocator_extend(allocator); \ @@ -47,8 +47,8 @@ extern char * #define fcs_compact_alloc_typed_ptr_into_var(result, type_t, allocator_orig, how_much_orig) \ { \ - register fcs_compact_allocator_t * allocator = (allocator_orig); \ - register int how_much = (how_much_orig); \ + fcs_compact_allocator_t * allocator = (allocator_orig); \ + int how_much = (how_much_orig); \ if (allocator->max_ptr - allocator->ptr < how_much) \ { \ freecell_solver_compact_allocator_extend(allocator); \ diff --git a/kpat/freecell-solver/lookup2.c b/kpat/freecell-solver/lookup2.c index 6ab9ae7e..e0f49f38 100644 --- a/kpat/freecell-solver/lookup2.c +++ b/kpat/freecell-solver/lookup2.c @@ -73,12 +73,12 @@ mix() was built out of 36 single-cycle latency instructions in a */ ub4 freecell_solver_lookup2_hash_function( - register ub1 *k, /* the key */ - register ub4 length, /* the length of the key */ - register ub4 initval /* the previous hash, or an arbitrary value */ + ub1 *k, /* the key */ + ub4 length, /* the length of the key */ + ub4 initval /* the previous hash, or an arbitrary value */ ) { - register ub4 a,b,c,len; + ub4 a,b,c,len; /* Set up the internal state */ len = length; diff --git a/kpat/freecell-solver/lookup2.h b/kpat/freecell-solver/lookup2.h index 002502ed..b689e64e 100644 --- a/kpat/freecell-solver/lookup2.h +++ b/kpat/freecell-solver/lookup2.h @@ -5,9 +5,9 @@ typedef unsigned long int ub4; /* unsigned 4-byte quantities */ typedef unsigned char ub1; ub4 freecell_solver_lookup2_hash_function( - register ub1 *k, /* the key */ - register ub4 length, /* the length of the key */ - register ub4 initval /* the previous hash, or an arbitrary value */ + ub1 *k, /* the key */ + ub4 length, /* the length of the key */ + ub4 initval /* the previous hash, or an arbitrary value */ ); #endif /* FC_SOLVE__LOOKUP2_H */ diff --git a/ksame/StoneField.cpp b/ksame/StoneField.cpp index 673e0e38..356986c2 100644 --- a/ksame/StoneField.cpp +++ b/ksame/StoneField.cpp @@ -329,8 +329,8 @@ StoneField::undo(int count) { bool StoneField::isGameover() const { - register int i=maxstone-1;; - register unsigned char color; + int i=maxstone-1;; + unsigned char color; if (gameover>=0) return (bool)gameover; // kdDebug() << "-->gameover" << endl;