about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog5
-rw-r--r--Src/subst.c3
2 files changed, 8 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index 643a33dac..df3f9b73c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2024-04-07  Mikael Magnusson  <mikachu@gmail.com>
+
+	* 52878: Src/subst.c: Fix ${foo:^bar} where bar is an associative
+	array
+
 2024-04-01  Bart Schaefer  <schaefer@zsh.org>
 
 	* 52865: Doc/Zsh/expn.yo, Doc/Zsh/params.yo, Etc/FAQ.yo:
diff --git a/Src/subst.c b/Src/subst.c
index f0d6c7a7b..a079672df 100644
--- a/Src/subst.c
+++ b/Src/subst.c
@@ -3475,6 +3475,9 @@ paramsubst(LinkList l, LinkNode n, char **str, int qt, int pf_flags,
 	    char *sval;
 	    zip = getaparam(s);
 	    if (!zip) {
+		zip = gethparam(s);
+	    }
+	    if (!zip) {
 		sval = getsparam(s);
 		if (sval)
 		    zip = hmkarray(sval);