From e5d5a76dce1cc488627c8623f0cd972c3d52644d Mon Sep 17 00:00:00 2001 From: Peter Stephenson Date: Fri, 21 Aug 2015 17:12:46 +0100 Subject: Test for 36265, no alias expansion after "function" --- ChangeLog | 9 +++++++++ Test/C04funcdef.ztst | 13 +++++++++++++ 2 files changed, 22 insertions(+) diff --git a/ChangeLog b/ChangeLog index 5c2cdf8f5..4166fcbe4 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,14 @@ 2015-08-21 Peter Stephenson + * 36268: Test/C04funcdef.ztst: test for 36265. + + * 36265 plus FAQ: fix alias expansion after "function" + Names after the first were treated as command words so had + non-global aliases expanded. Add an FAQ note that use of the + function keyword works around other alias problems. Also + fixes problem that "function { ... }" didn't work with + IGNORE_BRACES set. + * 36264: Src/glob.c: pathbuf is apparently metafied; document this and unmetafy for system calls. diff --git a/Test/C04funcdef.ztst b/Test/C04funcdef.ztst index 74f881587..0951e2cde 100644 --- a/Test/C04funcdef.ztst +++ b/Test/C04funcdef.ztst @@ -295,6 +295,19 @@ >} >This is the correct output. + unfunction command_not_found_handler # amusing but unhelpful + alias first='firstfn1 firstfn2' second='secondfn1 secondfn2' + function first second { print This is function $0; } + first + second + firstfn1 + secondfn1 +127:No alias expansion after "function" keyword +>This is function first +>This is function second +?(eval):6: command not found: firstfn1 +?(eval):7: command not found: secondfn1 + %clean rm -f file.in file.out -- cgit 1.4.1