[gdb/testsuite] Set completions to unlimited in get_set_option_choices
In some test-case I tried to use get_set_option_choices "set architecture" and
ran into max-completions:
...
set architecture simple^M
set architecture tomcat^M
set architecture xscale^M
set architecture *** List may be truncated, max-completions reached. ***^M
(gdb) PASS: gdb.base/foo.exp: complete set architecture
...
There's only one test-case using this currently: gdb.base/parse_number.exp,
and it locally sets max-completions to unlimited.
Fix this by:
- factoring out a new proc with_set out of proc with_complaints, and
- using it to temporarily set max-completions to unlimited in
get_set_option_choice.
Tested on x86_64-linux, by running test-cases that excercise
get_set_option_choice and with_complaints.