Timeline for zsh: pass variable by reference, and modify its value (like bash's local -n namerefs)?
Current License: CC BY-SA 4.0
9 events
| when toggle format | what | by | license | comment | |
|---|---|---|---|---|---|
| Jun 15, 2023 at 19:07 | comment | added | Mark Reed | note that this doesn't work for array variables; if you attempt to assign an array through a nameref using (P), you just get a string with space-separated items. | |
| Feb 10, 2023 at 7:21 | history | edited | Stéphane Chazelas | CC BY-SA 4.0 | added 163 characters in body |
| Dec 2, 2022 at 14:44 | comment | added | juanmirocks | Explanations: * (P) and the like are parameter expansions * The first expand and assign function definitions omit the curly brackets, which are optional for single-line definitions * The : character (ussed in assign) is the "no-op" command; e.g. explained here | |
| Jun 25, 2022 at 18:59 | history | edited | Stéphane Chazelas | CC BY-SA 4.0 | added 266 characters in body |
| Jun 25, 2022 at 15:16 | history | edited | Stéphane Chazelas | CC BY-SA 4.0 | added 24 characters in body |
| Jun 25, 2022 at 15:06 | history | edited | Stéphane Chazelas | CC BY-SA 4.0 | added 198 characters in body |
| Jun 25, 2022 at 14:49 | history | edited | Stéphane Chazelas | CC BY-SA 4.0 | added 157 characters in body |
| Jun 25, 2022 at 14:32 | history | edited | Stéphane Chazelas | CC BY-SA 4.0 | added 42 characters in body |
| Jun 25, 2022 at 14:23 | history | answered | Stéphane Chazelas | CC BY-SA 4.0 |