+2015-07-28 Luis Felipe Strano Moraes <luis.strano@gmail.com>
+ Manuel López-Ibáñez <manu@gcc.gnu.org>
+
+ * c-decl.c (get_parm_info): Remove static var. Update warning
+ message.
+
2015-07-27 Marek Polacek <polacek@redhat.com>
PR c++/66555
tree types = 0;
tree others = 0;
- static bool explained_incomplete_types = false;
bool gave_void_only_once_err = false;
arg_info->had_vla_unspec = current_scope->had_vla_unspec;
{
if (b->id)
/* The %s will be one of 'struct', 'union', or 'enum'. */
- warning (0, "%<%s %E%> declared inside parameter list",
- keyword, b->id);
+ warning_at (input_location, 0,
+ "%<%s %E%> declared inside parameter list"
+ " will not be visible outside of this definition or"
+ " declaration", keyword, b->id);
else
/* The %s will be one of 'struct', 'union', or 'enum'. */
- warning (0, "anonymous %s declared inside parameter list",
- keyword);
-
- if (!explained_incomplete_types)
- {
- warning (0, "its scope is only this definition or declaration,"
- " which is probably not what you want");
- explained_incomplete_types = true;
- }
+ warning_at (input_location, 0,
+ "anonymous %s declared inside parameter list"
+ " will not be visible outside of this definition or"
+ " declaration", keyword);
}
tag.id = b->id;
+2015-07-28 Luis Felipe Strano Moraes <luis.strano@gmail.com>
+ Manuel López-Ibáñez <manu@gcc.gnu.org>
+
+ * gcc.dg/parm-incomplete-1.c: Update.
+ * gcc.dg/pr18809-1.c: Update.
+ * gcc.dg/pr27953.c: Update.
+ * gcc.dg/vla-11.c: Update.
+
2015-07-27 Marek Polacek <polacek@redhat.com>
* c-c++-common/Wtautological-compare-2.c: Remove unused line.
void foo11b(__SIZE_TYPE__ x, int y[(__UINTPTR_TYPE__)(int (*)[*])x]); /* { dg-warning "not in a declaration" } */
void foo11c(struct s { int (*x)[*]; } *y); /* { dg-error "a member of a structure or union cannot have a variably modified type" "variably modified" } */
/* { dg-warning "'struct s' declared inside parameter list" "struct decl" { target *-*-* } 11 } */
-/* { dg-warning "its scope is only this definition or declaration" "struct scope" { target *-*-* } 11 } */