parser perversities (was Re: make install failed; dump core in mkdir)

2019-12-12 Thread L A Walsh
On 2019/12/02 07:04, pepa65 wrote: it would be nice to be able to omit 'do'. like: set -- 1 2 3 for i { echo $i } 1 2 3 or: for i;{ echo $i;} 1 2 3

Re: make install failed; dump core in mkdir

2019-12-02 Thread Greg Wooledge
On Mon, Dec 02, 2019 at 01:41:11PM -0500, Chet Ramey wrote: > On 12/1/19 10:20 AM, George R Goffe via Bug reports for the GNU Bourne > Again SHell wrote: > > mkdir () > > { > > dirs="$@"; > > for dir in $dirs; > > do > > /bin/mkdir -p "$dir"; > > done > > } > > > > > > > > make[1]: Leaving dire

Re: make install failed; dump core in mkdir

2019-12-02 Thread Chet Ramey
On 12/1/19 10:20 AM, George R Goffe via Bug reports for the GNU Bourne Again SHell wrote: > Hi, > > This is really strange. I just did a buld of bash-5.0 from ftp.gnu.org. build > went well... but make install coredumped in mkdir. mkdir is in my > bashrc...This is not a new change to the bash rc

Re: make install failed; dump core in mkdir

2019-12-02 Thread Greg Wooledge
On Mon, Dec 02, 2019 at 10:06:36AM -0500, Eli Schwartz wrote: > But I think I'll still use them despite being not strictly needed, or > I'll just confuse myself once I do need them. :p I've used them for too > long by now, anyway. Yeah, same here. I prefer it with the semicolon.

Re: make install failed; dump core in mkdir

2019-12-02 Thread Eli Schwartz
On 12/2/19 9:56 AM, Greg Wooledge wrote: > On Mon, Dec 02, 2019 at 09:51:12PM +0700, pepa65 wrote: >> On 12/2/19 9:38 PM, Andreas Kusalananda Kähäri wrote:> for dirpath do >>> command mkdir -p "$dirpath" || return >>> done >> It is very sad that the 'do' is not optional (non-back

Re: make install failed; dump core in mkdir

2019-12-02 Thread pepa65
On 12/2/19 9:56 PM, Greg Wooledge wrote:> You're mistaken. > > wooledg:~$ set -- a b c > wooledg:~$ for i do echo "$i"; done > a > b > c Foot in mouth. I was unfamiliar with this syntax that I guess only works when no 'in' is used. Still, for the other cases, it would be nice to be able to omit

Re: make install failed; dump core in mkdir

2019-12-02 Thread Greg Wooledge
On Mon, Dec 02, 2019 at 09:51:12PM +0700, pepa65 wrote: > On 12/2/19 9:38 PM, Andreas Kusalananda Kähäri wrote:> for dirpath do > > command mkdir -p "$dirpath" || return > > done > It is very sad that the 'do' is not optional (non-backwards compatibility > breaking feature reques

Re: make install failed; dump core in mkdir

2019-12-02 Thread pepa65
On 12/2/19 9:38 PM, Andreas Kusalananda Kähäri wrote:> for dirpath do > command mkdir -p "$dirpath" || return > done It is very sad that the 'do' is not optional (non-backwards compatibility breaking feature request!), and it has to be the start of the next commandline (after

Re: make install failed; dump core in mkdir

2019-12-02 Thread Andreas Kusalananda Kähäri
On Mon, Dec 02, 2019 at 08:51:27AM -0500, Greg Wooledge wrote: > On Sun, Dec 01, 2019 at 03:20:54PM +, George R Goffe via Bug reports for > the GNU Bourne Again SHell wrote: > > mkdir () > > { > > dirs="$@"; > > for dir in $dirs; > > do > > /bin/mkdir -p "$dir"; > > done > > } > > This funct

Re: make install failed; dump core in mkdir

2019-12-02 Thread Greg Wooledge
On Sun, Dec 01, 2019 at 03:20:54PM +, George R Goffe via Bug reports for the GNU Bourne Again SHell wrote: > mkdir () > { > dirs="$@"; > for dir in $dirs; > do > /bin/mkdir -p "$dir"; > done > } This function is severely flawed. I believe this is what you wanted: mkdir() { command mkdir