output explicit types (int16_t, int32_t, etc) rather than (short, long, ...)
This commit is contained in:
parent
a31739bc01
commit
caf41deb2a
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: rpc_hout.c,v 1.7 1997/10/18 10:53:48 lukem Exp $ */
|
||||
/* $NetBSD: rpc_hout.c,v 1.8 1998/02/10 05:10:19 lukem Exp $ */
|
||||
/*
|
||||
* Sun RPC is a product of Sun Microsystems, Inc. and is provided for
|
||||
* unrestricted use provided that this legend is included on all tape
|
||||
@ -34,7 +34,7 @@
|
||||
#if 0
|
||||
static char sccsid[] = "@(#)rpc_hout.c 1.12 89/02/22 (C) 1987 SMI";
|
||||
#else
|
||||
__RCSID("$NetBSD: rpc_hout.c,v 1.7 1997/10/18 10:53:48 lukem Exp $");
|
||||
__RCSID("$NetBSD: rpc_hout.c,v 1.8 1998/02/10 05:10:19 lukem Exp $");
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@ -241,7 +241,7 @@ puldefine(name, num)
|
||||
char *name;
|
||||
char *num;
|
||||
{
|
||||
f_print(fout, "#define %s ((u_long)%s)\n", name, num);
|
||||
f_print(fout, "#define %s ((u_int32_t)%s)\n", name, num);
|
||||
}
|
||||
|
||||
static int
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: rpc_parse.c,v 1.7 1997/10/18 10:53:57 lukem Exp $ */
|
||||
/* $NetBSD: rpc_parse.c,v 1.8 1998/02/10 05:10:20 lukem Exp $ */
|
||||
/*
|
||||
* Sun RPC is a product of Sun Microsystems, Inc. and is provided for
|
||||
* unrestricted use provided that this legend is included on all tape
|
||||
@ -34,7 +34,7 @@
|
||||
#if 0
|
||||
static char sccsid[] = "@(#)rpc_parse.c 1.8 89/02/22 (C) 1987 SMI";
|
||||
#else
|
||||
__RCSID("$NetBSD: rpc_parse.c,v 1.7 1997/10/18 10:53:57 lukem Exp $");
|
||||
__RCSID("$NetBSD: rpc_parse.c,v 1.8 1998/02/10 05:10:20 lukem Exp $");
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@ -573,13 +573,16 @@ get_type(prefixp, typep, dkind)
|
||||
unsigned_dec(typep);
|
||||
break;
|
||||
case TOK_SHORT:
|
||||
*typep = "short";
|
||||
*typep = "int16_t";
|
||||
(void) peekscan(TOK_INT, &tok);
|
||||
break;
|
||||
case TOK_LONG:
|
||||
*typep = "long";
|
||||
*typep = "int32_t";
|
||||
(void) peekscan(TOK_INT, &tok);
|
||||
break;
|
||||
case TOK_INT:
|
||||
*typep = "int32_t";
|
||||
break;
|
||||
case TOK_VOID:
|
||||
if (dkind != DEF_UNION && dkind != DEF_PROGRAM) {
|
||||
error("voids allowed only inside union and program definitions with one argument");
|
||||
@ -589,7 +592,6 @@ get_type(prefixp, typep, dkind)
|
||||
case TOK_STRING:
|
||||
case TOK_OPAQUE:
|
||||
case TOK_CHAR:
|
||||
case TOK_INT:
|
||||
case TOK_FLOAT:
|
||||
case TOK_DOUBLE:
|
||||
case TOK_BOOL:
|
||||
@ -614,20 +616,20 @@ unsigned_dec(typep)
|
||||
break;
|
||||
case TOK_SHORT:
|
||||
get_token(&tok);
|
||||
*typep = "u_short";
|
||||
*typep = "u_int16_t";
|
||||
(void) peekscan(TOK_INT, &tok);
|
||||
break;
|
||||
case TOK_LONG:
|
||||
get_token(&tok);
|
||||
*typep = "u_long";
|
||||
*typep = "u_int32_t";
|
||||
(void) peekscan(TOK_INT, &tok);
|
||||
break;
|
||||
case TOK_INT:
|
||||
get_token(&tok);
|
||||
*typep = "u_int";
|
||||
*typep = "u_int32_t";
|
||||
break;
|
||||
default:
|
||||
*typep = "u_int";
|
||||
*typep = "u_int32_t";
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user