Properly use opts in finish_options
authorRichard Biener <rguenther@suse.de>
Tue, 10 May 2022 07:47:06 +0000 (09:47 +0200)
committerRichard Biener <rguenther@suse.de>
Thu, 19 May 2022 11:58:21 +0000 (13:58 +0200)
commitad4fa189a7b6cbe183a4b1a99ca67888e68d7532
treeabe01935759ec0e1c5d75543d21df4c6dc1f2e28
parent1e43783b3f3570f59bbe80fe38ba65049fa77a0a
Properly use opts in finish_options

When code was moved from process_options to finish_options it
was not properly adjusted to look at and alter the opts set
passed to the function but continued to modify the global options
set.  The following rectifies this and makes sure the same
mistake isn't repeated by poisoning global_options{,_set}.

2022-05-10  Richard Biener  <rguenther@suse.de>

* flags.h (dwarf_debuginfo_p): Add opts argument, guard
API with !GENERATOR_FILE.
* opts.cc (global_options): Poison.
(global_options_set): Likewise.
(finish_options): Refer to options via opts.

(cherry picked from commit d4694846102a9589558dd509ef70b7960063935d)
gcc/flags.h
gcc/opts.cc