From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from gatech.edu (gatech.edu [130.207.244.244]) by werple.net.au (8.7/8.7) with SMTP id EAA00691 for ; Fri, 13 Oct 1995 04:26:49 +1000 (EST) Received: from gauss (gauss.skiles.gatech.edu) by gatech.edu with SMTP id AA16092 (5.65c/Gatech-10.0-IDA for ); Thu, 12 Oct 1995 14:24:22 -0400 Received: by gauss (5.x/SMI-SVR4) id AA08348; Thu, 12 Oct 1995 14:23:23 -0400 Resent-Date: Thu, 12 Oct 1995 14:19:56 -0400 Old-Return-Path: Message-Id: <9510121819.AA03938@redwood.skiles.gatech.edu> X-Mailer: exmh version 1.6.4 10/10/95 To: Zoltan Hidvegi Cc: zsh-workers@math.gatech.edu Subject: ksh compatibility In-Reply-To: Your message of "Thu, 12 Oct 1995 13:07:41 BST." <199510121207.NAA13791@bolyai.cs.elte.hu> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Thu, 12 Oct 1995 14:19:56 -0400 From: Richard Coleman Resent-Message-Id: <"OFwjV1.0.E22.QqLVm"@gauss> Resent-From: zsh-workers@math.gatech.edu X-Mailing-List: archive/latest/452 X-Loop: zsh-workers@math.gatech.edu Precedence: list Resent-Sender: zsh-workers-request@math.gatech.edu > > According to the "Korn Shell Ref" card (updated for ksh93) from SSC > > > > [[ str == pat ]] > > > > is preferred and > > > > [[ str = pat ]] > > > > is "obsolete" (but still works of course). > > > > Can the == for [[ be added to zsh? We've got some code that > > needs to work on both ksh and zsh so it would be nice... > > My ksh manual from Solaris 5.4 (Last change: 3 Aug 1993) does not mention > this, but I tried the ksh here, and it accepted the == syntax. Here is a > patch to zsh to do that. This makes [[ ... = ... ]] and [[ ... == ... ]] > equivalent. Notice that he said ksh93. I think Solaris uses ksh89. Also, I will probably add this since I think == is a more logical way of representing this. But I must stress something important: The goal of zsh is not to be a ksh clone. The goal of zsh (as far as I'm concerned) is to be a powerful superset of sh that is especially good at interactive use. The ksh compatibility we have now is more a matter of convenience than the result of explicitly trying to copy ksh. Maintaining ksh compatibility for common commands is a good idea, but I see no compelling reason to copy every last detail of ksh. Richard Coleman coleman@math.gatech.edu