mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-10-16 12:24:19 +08:00
PR ld/11006
* lexsup.c (parse_args): Allow nested --start-group, --end-group.
This commit is contained in:
@ -1,3 +1,8 @@
|
|||||||
|
2009-11-30 Alan Modra <amodra@bigpond.net.au>
|
||||||
|
|
||||||
|
PR ld/11006
|
||||||
|
* lexsup.c (parse_args): Allow nested --start-group, --end-group.
|
||||||
|
|
||||||
2009-11-27 Tristan Gingold <gingold@adacore.com>
|
2009-11-27 Tristan Gingold <gingold@adacore.com>
|
||||||
|
|
||||||
* pe-dll.c (pe_implied_import_dll): Return early if there is no
|
* pe-dll.c (pe_implied_import_dll): Return early if there is no
|
||||||
|
12
ld/lexsup.c
12
ld/lexsup.c
@ -1459,18 +1459,15 @@ parse_args (unsigned argc, char **argv)
|
|||||||
command_line.accept_unknown_input_arch = FALSE;
|
command_line.accept_unknown_input_arch = FALSE;
|
||||||
break;
|
break;
|
||||||
case '(':
|
case '(':
|
||||||
if (ingroup)
|
|
||||||
einfo (_("%P%F: may not nest groups (--help for usage)\n"));
|
|
||||||
|
|
||||||
lang_enter_group ();
|
lang_enter_group ();
|
||||||
ingroup = 1;
|
ingroup++;
|
||||||
break;
|
break;
|
||||||
case ')':
|
case ')':
|
||||||
if (! ingroup)
|
if (! ingroup)
|
||||||
einfo (_("%P%F: group ended before it began (--help for usage)\n"));
|
einfo (_("%P%F: group ended before it began (--help for usage)\n"));
|
||||||
|
|
||||||
lang_leave_group ();
|
lang_leave_group ();
|
||||||
ingroup = 0;
|
ingroup--;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case OPTION_INIT:
|
case OPTION_INIT:
|
||||||
@ -1501,8 +1498,11 @@ parse_args (unsigned argc, char **argv)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (ingroup)
|
while (ingroup)
|
||||||
|
{
|
||||||
lang_leave_group ();
|
lang_leave_group ();
|
||||||
|
ingroup--;
|
||||||
|
}
|
||||||
|
|
||||||
if (default_dirlist != NULL)
|
if (default_dirlist != NULL)
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user