mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-06-05 23:26:51 +08:00
Remove more "struct" keywords in range-based for loops
GCC 6.3.0 produces this kind of errors: CXX dwarf2read.o /home/simark/src/binutils-gdb/gdb/dwarf2read.c: In function 'void process_cu_includes(dwarf2_per_objfile*)': /home/simark/src/binutils-gdb/gdb/dwarf2read.c:10220:8: error: types may not be defined in a for-range-declaration [-Werror] for (struct dwarf2_per_cu_data *iter : dwarf2_per_objfile->just_read_cus) ^~~~~~ Removing the struct keyword makes it happy. gdb/ChangeLog: * dwarf2read.c (process_cu_includes): Remove struct keyword. * serial.c (serial_interface_lookup): Remove struct keyword.
This commit is contained in:
@ -143,7 +143,7 @@ serial_log_command (struct target_ops *self, const char *cmd)
|
||||
static const struct serial_ops *
|
||||
serial_interface_lookup (const char *name)
|
||||
{
|
||||
for (const struct serial_ops *ops : serial_ops_list)
|
||||
for (const serial_ops *ops : serial_ops_list)
|
||||
if (strcmp (name, ops->name) == 0)
|
||||
return ops;
|
||||
|
||||
|
Reference in New Issue
Block a user