zsh-workers
 help / color / mirror / code / Atom feed
From: Zefram <zefram@dcs.warwick.ac.uk>
To: pws@ifh.de (Peter Stephenson)
Cc: zsh-workers@math.gatech.edu
Subject: Re: Handling for ZLE modules
Date: Fri, 8 Nov 1996 17:16:46 +0000 (GMT)	[thread overview]
Message-ID: <28077.199611081716@stone.dcs.warwick.ac.uk> (raw)
In-Reply-To: <199611081526.QAA01276@hydra.ifh.de> from "Peter Stephenson" at Nov 8, 96 04:26:04 pm

>The other question is how to handle unloading.  One has to be careful
>when bindings remain which point to the function; also, the functions
>are in a linear array like the builtin functions and you may not be
>deleting at the end.  I have arranged it so that the function is
>marked as deleted with name "<deleted>" (which should only be used for
>output), but the table entry is kept.

I don't like this.  Do we retain the binding or not?  If not, we have
to go through every key binding, changing them to undefined-key.  The
alternative would be to maintain link counts for loaded bindings, to
avoid reusing a slot that is bound to some key.

>                             This seems to me a problem to be fixed in
>any script code associated with the (z?)modload -u,

No.  It's a question of the integrity of zsh's internal data
structures, and should be handled by the code itself.

On a related note, we really need to make addbuiltin() and so on handle
failure cases gracefully.  Try loading mod_example.so twice ("modload
./mod_example.so; modload ~+/mod_example.so"): when I tried it it
segmentated.  Modules are going to have to cope with the possibility
that they can't add the builtins, key bindings or whatever that they
want.

And if anyone's counting, I, too, favour the name `zmodload'.

-zefram

(Own up, how many of us are planning how to implement autoloaded modules?)


  reply	other threads:[~1996-11-08 17:27 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1996-11-08 15:26 Peter Stephenson
1996-11-08 17:16 ` Zefram [this message]
1996-11-08 17:26   ` Bruce Stephens
1996-11-10 23:55   ` Zoltan Hidvegi
1996-11-11 13:07   ` Peter Stephenson
     [not found] ` <pws@ifh.de>
1996-11-08 16:45   ` Bart Schaefer
1996-11-11 16:02   ` Bart Schaefer
1996-11-13 18:53   ` zle_refresh trial patch (and unrelated bug) Bart Schaefer
1996-11-14  9:03     ` Peter Stephenson
1996-11-14 14:57       ` Zefram
1996-11-09 10:22 zle_refresh trial patch Geoff Wing
     [not found] ` <gwing@primenet.com.au>
1996-11-09 17:09   ` zle_refresh trial patch (and unrelated bug) Bart Schaefer
1996-11-12 12:40     ` Peter Stephenson

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=28077.199611081716@stone.dcs.warwick.ac.uk \
    --to=zefram@dcs.warwick.ac.uk \
    --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).