--- a/src/regex.c
+++ b/src/regex.c
@@ -848,11 +848,13 @@ static const char *re_error_msg[] =
 
 /* Subroutine declarations and macros for regex_compile.  */
 
-static void store_op1 (), store_op2 ();
-static void insert_op1 (), insert_op2 ();
-static boolean at_begline_loc_p (), at_endline_loc_p ();
-static boolean group_in_compile_stack ();
-static reg_errcode_t compile_range ();
+static void store_op1 (re_opcode_t op, unsigned char *loc, int arg);
+static void store_op2 (re_opcode_t op, unsigned char *loc, int arg1, int arg2);
+static void insert_op1 (re_opcode_t op, unsigned char *loc, int arg, unsigned char *end);
+static void insert_op2 (re_opcode_t op, unsigned char *loc, int arg1, int arg2, unsigned char *end);
+static boolean at_begline_loc_p (const char *pattern, const char *p, reg_syntax_t syntax);
+static boolean at_endline_loc_p (const char *p, const char *pend, int syntax);
+static reg_errcode_t compile_range (const char **p_ptr, const char *pend, char *translate, reg_syntax_t syntax, unsigned char *b);
 
 /* Fetch the next character in the uncompiled pattern---translating it 
    if necessary.  Also cast from a signed character in the constant
@@ -1006,6 +1008,7 @@ typedef struct
   unsigned avail;			/* Offset of next open position.  */
 } compile_stack_type;
 
+static boolean group_in_compile_stack (compile_stack_type compile_stack, regnum_t regnum);
 
 #define INIT_COMPILE_STACK_SIZE 32
 
@@ -3000,10 +3003,7 @@ re_search_2 (bufp, string1, size1, strin
 
 /* Declarations and macros for re_match_2.  */
 
-static int bcmp_translate ();
-static boolean alt_match_null_string_p (),
-               common_op_match_null_string_p (),
-               group_match_null_string_p ();
+static int bcmp_translate (unsigned char *s1, unsigned char *s2, register int len, char *translate);
 
 /* Structure for per-register (a.k.a. per-group) information.
    This must not be longer than one word, because we push this value
@@ -3031,6 +3031,10 @@ typedef union
   } bits;
 } register_info_type;
 
+static boolean alt_match_null_string_p (unsigned char *p, unsigned char *end, register_info_type *reg_info);
+static boolean common_op_match_null_string_p (unsigned char **p, unsigned char *end, register_info_type *reg_info);
+static boolean group_match_null_string_p (unsigned char **p, unsigned char *end, register_info_type *reg_info);
+
 #define REG_MATCH_NULL_STRING_P(R)  ((R).bits.match_null_string_p)
 #define IS_ACTIVE(R)  ((R).bits.is_active)
 #define MATCHED_SOMETHING(R)  ((R).bits.matched_something)
