Date: Mon, 6 Mar 2000 12:09:02 -0500 From: Chet Ramey <chet@nike.ins.cwru.edu> To: jhix@mindspring.com Cc: Doug@gorean.org, hackers@FreeBSD.ORG Subject: Re: empty lists in for Message-ID: <1000306170902.AA22857.SM@nike.ins.cwru.edu>
next in thread | raw e-mail | index | archive | help
> Even though it's my preferred shell, I certainly wouldn't say > that Bash is any sort of standard, certainly not in the POSIX > sense. Bash implements the POSIX.2 standard, with certain well-defined exceptions (`posix mode'). > Imagine processing a possibly empty list constructed from a > 'make' expansion... Without this behavior one would have to > code a guard of some sort around the 'for' construct. The idiomatic solution for this sort of thing is changing your makefile recipes from for f in ${SUBDIRS} do ... to sh_subdirs=${SUBDIRS}; for f in $$sh_subdirs ; do ... -- ``The lyf so short, the craft so long to lerne.'' - Chaucer ( ``Discere est Dolere'' -- chet) Chet Ramey, CWRU chet@po.CWRU.Edu http://cnswww.cns.cwru.edu/~chet/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1000306170902.AA22857.SM>