Xref: utzoo comp.bugs.sys5:1170 comp.bugs.4bsd:1448 Newsgroups: comp.bugs.sys5,comp.bugs.4bsd Path: utzoo!henry From: henry@utzoo.uucp (Henry Spencer) Subject: Re: s/A*./B/g editor bug? Message-ID: <1989Oct19.164712.21326@utzoo.uucp> Organization: U of Toronto Zoology References: <3522@aplcen.apl.jhu.edu> <741@ccssrv.UUCP> Date: Thu, 19 Oct 89 16:47:12 GMT In article <741@ccssrv.UUCP> perry@ccssrv.UUCP (Perry Hutchison) writes: >+ s/b*a/c/g >+ on the input line >+ aaaaaaaaaaaaaaaaaaaaa >+ -- the result is: >+ cacacacacacacacacacac >+ Both VI and ED behave this way, on at least System V.2 and Ultrix-32 V3.1. > >Both also behave this way on SunOS 3.5, which is a 4.2 BSD derivative. >Anyone care to try it out on a 2bsd or a V7 system? Using our ed, which although it runs on a Sun is a V6-derived program, I get the right answer. Looks like somebody broke it -- Berkeley, for a guess, but I could be wrong -- and everyone else blindly copied the mistake. (I unfortunately don't have a V7 ed source handy to check; just conceivably it was broken there, although it would surprise me.) -- A bit of tolerance is worth a | Henry Spencer at U of Toronto Zoology megabyte of flaming. | uunet!attcan!utzoo!henry henry@zoo.toronto.edu