Picking 2 allows old scripts that work to keep working. Changing to 1
would change the functionality of formerly working scripts in very
undesirable ways. ;-)

> 1. BASHPID is readonly, therefore assignment to it is fatal and the script 
> exits
> (with an error message printed). That's what my previous patch did.
> 
> 2. BASHPID is not read-only, but changes to it are discarded (with the null
> assignement function). Assignments to BASHPID are non-fatal, and it's possible
> to unset it. Once it's unset, it's magical meaning is lost. (I think this is
> what Chet is proposing). noro_bashpid.patch
> 
>> In what possible context would assigning to any of these variables make
>> sense, or be an indication of anything other than a fatal bug in the
>> script? I think they should all be readonly, and produce a proper
>> diagnostic error message upon exit if assigning is attempted.
> [...]
> 
> I wonder the same thing. I don't understand the reasoning for picking (2).
> 

Reply via email to