mirror of
git://git.tartarus.org/simon/puzzles.git
synced 2025-04-20 23:51:29 -07:00
Add missing 'static' to game-internal declarations.
Another thing I spotted while trawling the whole source base was that a couple of games had omitted 'static' on a lot of their internal functions. Checking with nm, there turned out to be quite a few more than I'd spotted by eye, so this should fix them all. Also added one missing 'const', on the lookup table nbits[] in Tracks.
This commit is contained in:
8
pearl.c
8
pearl.c
@ -282,8 +282,8 @@ static const char *validate_params(const game_params *params, bool full)
|
||||
* Solver.
|
||||
*/
|
||||
|
||||
int pearl_solve(int w, int h, char *clues, char *result,
|
||||
int difficulty, bool partial)
|
||||
static int pearl_solve(int w, int h, char *clues, char *result,
|
||||
int difficulty, bool partial)
|
||||
{
|
||||
int W = 2*w+1, H = 2*h+1;
|
||||
short *workspace;
|
||||
@ -921,7 +921,7 @@ struct pearl_loopgen_bias_ctx {
|
||||
|
||||
grid *g;
|
||||
};
|
||||
int pearl_loopgen_bias(void *vctx, char *board, int face)
|
||||
static int pearl_loopgen_bias(void *vctx, char *board, int face)
|
||||
{
|
||||
struct pearl_loopgen_bias_ctx *ctx = (struct pearl_loopgen_bias_ctx *)vctx;
|
||||
grid *g = ctx->g;
|
||||
@ -1048,7 +1048,7 @@ int pearl_loopgen_bias(void *vctx, char *board, int face)
|
||||
return ctx->score;
|
||||
}
|
||||
|
||||
void pearl_loopgen(int w, int h, char *lines, random_state *rs)
|
||||
static void pearl_loopgen(int w, int h, char *lines, random_state *rs)
|
||||
{
|
||||
grid *g = grid_new(GRID_SQUARE, w-1, h-1, NULL);
|
||||
char *board = snewn(g->num_faces, char);
|
||||
|
Reference in New Issue
Block a user