diff options
author | 2005-08-03 18:36:00 -0700 | |
---|---|---|
committer | 2005-08-03 18:36:00 -0700 | |
commit | 2c36119df5a9bf9ad04f665961721fdeb7ca7551 (patch) | |
tree | 295dc51738bf051de50b581c7ccb5c5fe220e146 /compile-i386.c | |
parent | Get closer to parsing multiple files correctly. (diff) | |
download | sparse-2c36119df5a9bf9ad04f665961721fdeb7ca7551.tar.gz sparse-2c36119df5a9bf9ad04f665961721fdeb7ca7551.tar.bz2 sparse-2c36119df5a9bf9ad04f665961721fdeb7ca7551.zip |
Update the calling interface to "sparse()".
Start off with
sparse_initialize(argc, argv);
which will return the number of filenames found. You can then use that,
or just check if *argv is NULL in a loop like
while (*argv)
list = sparse(argv);
where you get the declaration list for each file in turn.
Diffstat (limited to 'compile-i386.c')
-rw-r--r-- | compile-i386.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/compile-i386.c b/compile-i386.c index f2f7de7..9ea09ed 100644 --- a/compile-i386.c +++ b/compile-i386.c @@ -1983,6 +1983,8 @@ static struct storage *x86_statement(struct statement *stmt) if (!stmt) return NULL; switch (stmt->type) { + default: + return NULL; case STMT_RETURN: return emit_return_stmt(stmt); case STMT_COMPOUND: { @@ -2323,6 +2325,8 @@ static struct storage *x86_expression(struct expression *expr) } switch (expr->type) { + default: + return NULL; case EXPR_CALL: return x86_call_expression(expr); |