zsh-workers
 help / color / mirror / code / Atom feed
From: Zoltan Hidvegi <hzoli@cs.elte.hu>
To: pws@ifh.de (Peter Stephenson)
Cc: zsh-workers@math.gatech.edu
Subject: Re: execcmd() reordering
Date: Thu, 30 May 1996 20:00:50 +0200 (MET DST)	[thread overview]
Message-ID: <199605301800.UAA31169@bolyai.cs.elte.hu> (raw)
In-Reply-To: <199605301658.SAA21722@hydra.ifh.de> from Peter Stephenson at "May 30, 96 06:58:29 pm"

> 1) exec, noglob, - and command are treated more like commands; they can
> appear from substitution, though not globbing (which would be stupid).

Yes stupid, but that's how other shells behave.  But since noglob must be
detected before globlist() that's the best we can do.

> 6) globbing is expanded before the fork.  Other than getting the
> prompt back an iota later when running background commands, I don't
> see this is a big deal.  One thing which seems to be a plus is that
> failures to match are now handled synchronously for background
> commands:

Also it makes debugging much easier.  Now prefork is really a historic
name.  There used to be prefork and postfork and a lot of substitutions had
been done in the later.

> 8)  fixcline() got moved up. This means things in the command line which
> expand to nothing are removed (if completely blank), or untokenised
> (if something like '') earlier.  The only consequent changes are that
> for AUTOCD the word mustn't be completely blank, since
> otherwise "$nonexistent" would have caused cd to home, which is a
> little counterintuitive.  Also, `[' doesn't need specially
> untokenising any more --- this must be a sign we're Doing the Right Thing.

Also makecline can be simplified after that patch.

>   (iv)  The new tests for `command', `exec', etc., are just simple
>         strcmp's.  It really didn't seem worth doing anything fancy
>         for four short strings.

I was thinking about adding these into builtintab with some new BINF_
flags: e.g. all of these would have BINF_PREFIX and there would be one more
BINF_ flag for each.  This would improve sh compatibility.  Hopefully a
hash-table lookup is not slower than these strcmps.  If something is found
with BINF_PREFIX shfunctab may be searched which may override builtintab
similarily to ksh.

Zoltan



  reply	other threads:[~1996-05-30 18:17 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1996-05-28  9:18 $(nooutput) problem Peter Stephenson
1996-05-28 11:34 ` Zoltan Hidvegi
1996-05-30 16:58   ` execcmd() reordering Peter Stephenson
1996-05-30 18:00     ` Zoltan Hidvegi [this message]
1996-05-30 18:26       ` Barton E. Schaefer
1996-05-30 18:46         ` Zoltan Hidvegi
1996-05-30 18:41       ` Zoltan Hidvegi
1996-05-30 18:05 Duncan Sinclair
1996-05-30 19:10 ` Zoltan Hidvegi
1996-05-30 19:52   ` Barton E. Schaefer
1996-05-31 14:32     ` Hrvoje Niksic
1996-05-31 10:15 Duncan Sinclair
1996-05-31 10:55 ` Zoltan Hidvegi
1996-05-31 11:58   ` Peter Stephenson
1996-05-31 16:28     ` Bart Schaefer

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=199605301800.UAA31169@bolyai.cs.elte.hu \
    --to=hzoli@cs.elte.hu \
    --cc=pws@ifh.de \
    --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).