Path: utzoo!attcan!sobeco!onfcanim!zap!matrox!IRO.UMontreal.CA!bonnie.concordia.ca!thunder.mcrcim.mcgill.edu!snorkelwacker.mit.edu!bu.edu!att!tut.cis.ohio-state.edu!usenet.ins.cwru.edu!ncoast!allbery From: allbery@NCoast.ORG (Brandon S. Allbery KB8JRR) Newsgroups: comp.unix.shell Subject: Re: Finding the last arg Message-ID: <1991Jan8.015206.25214@NCoast.ORG> Date: 8 Jan 91 01:52:06 GMT References: <1990Dec27.060903.1604@onion.pdx.com> <1020@mwtech.UUCP> <443@minya.UUCP> Reply-To: allbery@ncoast.ORG (Brandon S. Allbery KB8JRR) Followup-To: comp.unix.shell Organization: North Coast Computer Resources (ncoast) Lines: 24 As quoted from <443@minya.UUCP> by jc@minya.UUCP (John Chambers): +--------------- | as ad-hoc as the above example implies? Is there perhaps some logical | structure underlying it all that would explain why | for last do :; done | and | for last | do : | done | both work but | for last;do :;done | doesn't? +--------------- I suspect a /bin/sh bug. I just tried it on an ancient ksh and an almost-as- old [ ;-) ] Xenix; Xenix sh barfed, but ksh accepted it. I'll try it under System V 3.2 /bin/sh tomorrow. ++Brandon -- Me: Brandon S. Allbery VHF/UHF: KB8JRR on 220, 2m, 440 Internet: allbery@NCoast.ORG Packet: KB8JRR @ WA8BXN America OnLine: KB8JRR AMPR: KB8JRR.AmPR.ORG [44.70.4.88] uunet!usenet.ins.cwru.edu!ncoast!allbery Delphi: ALLBERY