[PATCH] Fix minor portability issues including ISO C 23 prototypes.

2024-02-13 Thread Collin Funk
Hi, I noticed some compiler warnings that might be worth fixing. I wasn't sure if patches should have ChangeLog entries so I left it alone and tried to make it easy to copy paste for you. Feel free to use or ignore changes as you see fit. Thanks, Collin * lib/malloc/malloc.c (botch): Add correct

Re: It is possible to remove the readonly attribute from {BASH, SHELL}OPTS

2024-02-13 Thread Grisha Levit
On Wed, Jan 31, 2024, 14:10 Chet Ramey wrote: > Well, is this a "my arm hurts when I do this" problem, or should bash > restrict the types of attributes that can be set on readonly variables? > For the attributes that only affect future assignments ([iluc]), I think think it makes sense to eithe

Re: declare -Aa var

2024-02-13 Thread Chet Ramey
On 2/7/24 1:48 AM, Grisha Levit wrote: If given both the -a and -A flags and an existing scalar variable, declare will assign both attributes to the variable: $ V=X; declare -Aa V; echo $? 0 $ echo ${V@a} aA $ (declare -p V) Segmentation fault: 11 For the time bei

Re: declare -A +A

2024-02-13 Thread Chet Ramey
On 2/12/24 5:24 PM, Koichi Murase wrote: 2024年2月13日(火) 6:13 Chet Ramey : Only for indexed and associative arrays, since those are the attributes that cause changes in the underlying value storage format. That's different than turning the integer attribute on and off, for instance. Should it be

Re: [PATCH] ASS_NOEVAL for BASHOPTS and SHELLOPTS

2024-02-13 Thread Chet Ramey
On 2/7/24 1:43 AM, Grisha Levit wrote: (Prompted by the report from Emanuele Torre in [1]) The value of currently_executing_command is garbage when there is an error during assignment when popping the variable context: $ bash -c 'declare -i SHELLOPTS; f() { local -; set -f; }; f' |& cat -v

Re: Rendering the Bash man page with commercial Unix/System V nroff

2024-02-13 Thread Chet Ramey
On 2/12/24 4:26 PM, G. Branden Robinson wrote: Hi Chet, At 2024-02-12T14:45:30-0500, Chet Ramey wrote: On 2/12/24 2:00 PM, G. Branden Robinson wrote: I see that most of my proposed man page changes from the recent series landed in the devel branch. Thanks! I did notice that this one and its