Skip to content

Commit

Permalink
Compile time warnings
Browse files Browse the repository at this point in the history
Fix compile time warnings detected by gccc 4.2.
  • Loading branch information
ldoolitt authored and steveicarus committed Sep 21, 2007
1 parent 954579f commit bcc034f
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion Module.cc
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
4 changes: 2 additions & 2 deletions vvp/sfunc.cc
Original file line number Diff line number Diff line change
Expand Up @@ -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;
}
Expand All @@ -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;
Expand Down
2 changes: 1 addition & 1 deletion vvp/udp.cc
Original file line number Diff line number Diff line change
Expand Up @@ -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) {
Expand Down
2 changes: 1 addition & 1 deletion vvp/vvp_net.cc
Original file line number Diff line number Diff line change
Expand Up @@ -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;
}
Expand Down

0 comments on commit bcc034f

Please sign in to comment.