>From 714da4bb3a26957cbd65058f7fb4afca85f82ee2 Mon Sep 17 00:00:00 2001 From: Daniel Shahaf Date: Wed, 28 Sep 2016 13:15:04 +0000 Subject: [PATCH] Print two spaces in 'typeset -p' of assocs (tweaked for upstream 39704/0f5e670cde5f844680a20f986786249dfe983584) --- Src/params.c | 6 ++++-- Test/V10private.ztst | 2 +- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/Src/params.c b/Src/params.c index ef72cba44..39af27c40 100644 --- a/Src/params.c +++ b/Src/params.c @@ -5298,6 +5298,7 @@ printparamvalue(Param p, int printflags) if (!(printflags & PRINT_KV_PAIR)) { putchar('('); putchar(' '); + putchar(' '); } { HashTable ht = p->gsu.h->getfn(p); @@ -5309,9 +5310,10 @@ printparamvalue(Param p, int printflags) putchar(')'); break; } - if (printflags & PRINT_KV_PAIR) + if (printflags & PRINT_KV_PAIR) { putchar(' '); - else + putchar(' '); + } else putchar('\n'); } diff --git a/Test/V10private.ztst b/Test/V10private.ztst index 7ebf5a87f..d1d9b0887 100644 --- a/Test/V10private.ztst +++ b/Test/V10private.ztst @@ -128,7 +128,7 @@ print ${(kv)hash_test} 0:private hides value from surrounding scope in nested scope >typeset -a hash_test=( top level ) ->typeset -A hash_test=( in function ) +>typeset -A hash_test=( in function ) >typeset -g -a hash_test=( top level ) >array-local top level >top level