mirror of
https://github.com/mirror/make.git
synced 2024-12-30 23:10:52 +08:00
* src/function.c: Change int to uint to align with gmk_func_ptr
This commit is contained in:
parent
f8852311cc
commit
c2eddf9be2
@ -2516,14 +2516,14 @@ static struct function_table_entry function_table_init[] =
|
|||||||
/* These must come after the definition of function_table. */
|
/* These must come after the definition of function_table. */
|
||||||
|
|
||||||
static char *
|
static char *
|
||||||
expand_builtin_function (char *o, int argc, char **argv,
|
expand_builtin_function (char *o, unsigned int argc, char **argv,
|
||||||
const struct function_table_entry *entry_p)
|
const struct function_table_entry *entry_p)
|
||||||
{
|
{
|
||||||
char *p;
|
char *p;
|
||||||
|
|
||||||
if (argc < (int)entry_p->minimum_args)
|
if (argc < entry_p->minimum_args)
|
||||||
fatal (*expanding_var, strlen (entry_p->name),
|
fatal (*expanding_var, strlen (entry_p->name),
|
||||||
_("insufficient number of arguments (%d) to function '%s'"),
|
_("insufficient number of arguments (%u) to function '%s'"),
|
||||||
argc, entry_p->name);
|
argc, entry_p->name);
|
||||||
|
|
||||||
/* I suppose technically some function could do something with no arguments,
|
/* I suppose technically some function could do something with no arguments,
|
||||||
@ -2572,7 +2572,7 @@ handle_function (char **op, const char **stringp)
|
|||||||
int count = 0;
|
int count = 0;
|
||||||
char *abeg = NULL;
|
char *abeg = NULL;
|
||||||
char **argv, **argvp;
|
char **argv, **argvp;
|
||||||
int nargs;
|
unsigned int nargs;
|
||||||
|
|
||||||
beg = *stringp + 1;
|
beg = *stringp + 1;
|
||||||
|
|
||||||
@ -2684,11 +2684,11 @@ handle_function (char **op, const char **stringp)
|
|||||||
static char *
|
static char *
|
||||||
func_call (char *o, char **argv, const char *funcname UNUSED)
|
func_call (char *o, char **argv, const char *funcname UNUSED)
|
||||||
{
|
{
|
||||||
static int max_args = 0;
|
static unsigned int max_args = 0;
|
||||||
char *fname;
|
char *fname;
|
||||||
char *body;
|
char *body;
|
||||||
size_t flen;
|
size_t flen;
|
||||||
int i;
|
unsigned int i;
|
||||||
int saved_args;
|
int saved_args;
|
||||||
const struct function_table_entry *entry_p;
|
const struct function_table_entry *entry_p;
|
||||||
struct variable *v;
|
struct variable *v;
|
||||||
@ -2739,7 +2739,7 @@ func_call (char *o, char **argv, const char *funcname UNUSED)
|
|||||||
{
|
{
|
||||||
char num[INTSTR_LENGTH];
|
char num[INTSTR_LENGTH];
|
||||||
|
|
||||||
sprintf (num, "%d", i);
|
sprintf (num, "%u", i);
|
||||||
define_variable (num, strlen (num), *argv, o_automatic, 0);
|
define_variable (num, strlen (num), *argv, o_automatic, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2752,7 +2752,7 @@ func_call (char *o, char **argv, const char *funcname UNUSED)
|
|||||||
{
|
{
|
||||||
char num[INTSTR_LENGTH];
|
char num[INTSTR_LENGTH];
|
||||||
|
|
||||||
sprintf (num, "%d", i);
|
sprintf (num, "%u", i);
|
||||||
define_variable (num, strlen (num), "", o_automatic, 0);
|
define_variable (num, strlen (num), "", o_automatic, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user