aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/evaluate.c
diff options
context:
space:
mode:
Diffstat (limited to 'evaluate.c')
-rw-r--r--evaluate.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/evaluate.c b/evaluate.c
index 9990b57b..794f8425 100644
--- a/evaluate.c
+++ b/evaluate.c
@@ -2614,7 +2614,7 @@ static void handle_list_initializer(struct expression *expr,
int class, struct symbol *ctype, unsigned long mods)
{
struct expression *e, *last = NULL, *top = NULL, *next;
- int jumped = 0;
+ int jumped = 0; // has the last designator multiple levels?
if (expr->zero_init)
free_ptr_list(&expr->expr_list);
@@ -2647,7 +2647,7 @@ static void handle_list_initializer(struct expression *expr,
ctype->ident ? ": " : "",
get_type_name(struct_sym->type),
show_ident(struct_sym->ident));
- if (jumped) {
+ if (jumped && Wpast_deep_designator) {
warning(e->pos, "advancing past deep designator");
jumped = 0;
}