zsh-workers
 help / color / mirror / code / Atom feed
From: Bruce Stephens <stephens@math.ruu.nl>
To: zsh-workers@math.gatech.edu
Subject: Re: quoting bug, and comparisons with ksh93
Date: Fri, 21 Jun 1996 16:24:59 +0200	[thread overview]
Message-ID: <199606211424.QAA04218@bommel.math.ruu.nl> (raw)
In-Reply-To: Zoltan Hidvegi's message of Fri, 21 Jun 1996 16:03:50 +0200 (MET DST)

>>>>> "Zoltan" == Zoltan Hidvegi <hzoli@cs.elte.hu> writes:

>> >>>>> "Zefram" == Zefram <A.Main@dcs.warwick.ac.uk> writes:
>> 
>> > setopt SH_WORD_SPLIT
>> 
>> What does POSIX say?

> Zsh must be invoked as sh/ksh if you want POSIX.  Even is sh/ksh
> mode there are some minor incompatibilities between zsh and POSIX
> but these rarely cause problems.  Also the zsh documentation does
> not claim that zsh conforms to POSIX.  On my computer /bin/sh is a
> link to zsh and it works fine.

That sounds fine then.  It would be a shame to have SH_WORD_SPLIT be
the default: the current position is more logical, even if it does
sometimes fool me.

Moving to another topic, I was reading about ksh93 in the recent AT&T
book on reusable UNIX software.  They've extended the pattern syntax
so it's equivalent to egrep style regexps (my guess is that zsh's are
pretty close), and added the nice touch that some option of print will
convert from a regexp to a ksh pattern.  There are lots of handy
things for writing scripts, but I tend to use zsh only interactively,
so for all I know some of these may already exist, although some
definitely don't: I can't have a variable called a.fred, for example.

One interesting, and probably not too hard feature (now that TCL and
Perl have done it) is dynamic loading of commands (on systems which
support it).  The idea is that they've written a library of routines
wc(argc, argv), basename(argc, argv) and so on which are all POSIX
implementations of the commands of the same names (so you can wrap a
10 line main around them to get the POSIX commands), and if you want
(and your machine supports it), you can arrange for ksh to dynamically
load this library, making lots of commands builtins.  It would be a
nice addition to zsh, I think: the mechanism that Perl uses is more
complex, because of its different types, but TCL's extensions are just
bunches of routines which take (int argc, char **argv), so presumably
the mechanism it uses to dynamically load things could be borrowed.



  reply	other threads:[~1996-06-21 14:42 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1996-06-21 13:17 quoting bug Raymond Nijssen
1996-06-21 13:29 ` Zefram
1996-06-21 13:55   ` Bruce Stephens
1996-06-21 14:03     ` Zoltan Hidvegi
1996-06-21 14:24       ` Bruce Stephens [this message]
1996-06-21 14:37         ` quoting bug, and comparisons with ksh93 Zoltan Hidvegi
1996-06-21 14:17     ` quoting bug Zefram
1996-06-21 14:30       ` Zoltan Hidvegi
1996-06-21 14:43       ` Hrvoje Niksic
1996-06-21 15:18         ` Zefram
1996-06-21 14:48       ` Chet Ramey
1996-06-21 16:54   ` Raymond Nijssen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=199606211424.QAA04218@bommel.math.ruu.nl \
    --to=stephens@math.ruu.nl \
    --cc=zsh-workers@math.gatech.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).