projects
/
cparser
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
60ba480
)
Improve unused variable check.
author
Christoph Mallon
<christoph.mallon@gmx.de>
Tue, 21 Oct 2008 06:11:05 +0000
(06:11 +0000)
committer
Christoph Mallon
<christoph.mallon@gmx.de>
Tue, 21 Oct 2008 06:11:05 +0000
(06:11 +0000)
[r23057]
parser.c
patch
|
blob
|
history
diff --git
a/parser.c
b/parser.c
index
7f2bf55
..
4098ff3
100644
(file)
--- a/
parser.c
+++ b/
parser.c
@@
-1886,9
+1886,11
@@
static declaration_t *determine_lhs_decl(expression_t *const expr, declaration_t
case EXPR_ARRAY_ACCESS: {
expression_t *const ref = expr->array_access.array_ref;
declaration_t * decl = NULL;
- if (is_type_array(
skip_typeref(ref->base.type
))) {
+ if (is_type_array(
revert_automatic_type_conversion(ref
))) {
decl = determine_lhs_decl(ref, lhs_decl);
lhs_decl = decl;
+ } else {
+ mark_decls_read(expr->select.compound, lhs_decl);
}
mark_decls_read(expr->array_access.index, lhs_decl);
return decl;