[net.unix] tr differences s3-s5-BSD

allbery@ncoast.UUCP (Brandon Allbery) (06/21/86)

Expires:

Quoted from <4289@sun.uucp> ["Re: Variations across unices"], by guy@sun.UUCP...
+---------------
| Yes to the first (for some reason, the S5 and, I think, S3 versions of "tr"
| require the square brackets) and no to the second (the "1" refers to the
| first argument, and is not a numeric value).
+---------------

Not System III.

+---------------
| Unless there was a good reason to incompatibly change the syntax of "tr"
| from what AT&T's own V7 supported, one could argue that the USDL perpetrated
| a bad joke on us all by doing so....
+---------------

My theory was that either (1) since character ranges are [x-y] in other
programs, they should be that way in tr just to make all programs act the same
way, or (2) [x-y] makes it possible to easily translate a hyphen.  I prefer
(1); it makes a kind of (skewed, but what's new with AT&T?) sense.

--Brandon
-- 
ihnp4!sun!cwruecmp!ncoast!allbery ncoast!allbery@Case.CSNET ncoast!tdi2!brandon
(ncoast!tdi2!root for business) 6615 Center St. #A1-105, Mentor, OH 44060-4101
Phone: +01 216 974 9210      CIS 74106,1032      MCI MAIL BALLBERY (part-time)