Compile time warnings

Fix compile time warnings detected by gccc 4.2.
This commit is contained in:
Larry Doolittle 2007-09-20 17:20:48 -07:00 committed by Stephen Williams
parent 954579f250
commit bcc034f634
4 changed files with 5 additions and 5 deletions

View File

@ -92,7 +92,7 @@ const svector<PEIdent*>& Module::get_port(unsigned idx) const
unsigned Module::find_port(const char*name) const
{
assert(name != "");
assert(name != 0);
for (unsigned idx = 0 ; idx < ports.count() ; idx += 1) {
if (ports[idx] == 0) {
/* It is possible to have undeclared ports. These

View File

@ -95,7 +95,7 @@ static int make_vpi_argv(unsigned argc, vpiHandle*vpi_argv,
break;
default:
fprintf(stderr, "Unsupported type %c(%d).\n", *cp);
fprintf(stderr, "Unsupported type %c(%d).\n", *cp, *cp);
assert(0);
break;
}
@ -118,7 +118,7 @@ static int make_vpi_argv(unsigned argc, vpiHandle*vpi_argv,
}
default:
fprintf(stderr, "Unsupported type %c(%d).\n", *cp);
fprintf(stderr, "Unsupported type %c(%d).\n", *cp, *cp);
assert(0);
}
idx += 1;

View File

@ -228,7 +228,7 @@ void vvp_udp_comb_s::compile_table(char**tab)
cur.maskx = 0;
if (port_count() > 8*sizeof(cur.mask0)) {
fprintf(stderr, "internal error: primitive port count=%u "
" > %d\n", port_count(), sizeof(cur.mask0));
" > %zu\n", port_count(), sizeof(cur.mask0));
assert(port_count() <= 8*sizeof(cur.mask0));
}
for (unsigned pp = 0 ; pp < port_count() ; pp += 1) {

View File

@ -1455,7 +1455,7 @@ void vvp_fun_signal_base::recv_long(vvp_net_ptr_t ptr, long bit)
release(ptr, false);
break;
default:
fprintf(stderr, "Unsupported command %d.\n", bit);
fprintf(stderr, "Unsupported command %ld.\n", bit);
assert(0);
break;
}