zsh-workers
 help / color / mirror / code / Atom feed
* Granularity of zcompile header magic
@ 2015-02-13  4:09 Bart Schaefer
  2015-02-13 10:24 ` Peter Stephenson
  0 siblings, 1 reply; 2+ messages in thread
From: Bart Schaefer @ 2015-02-13  4:09 UTC (permalink / raw)
  To: zsh-workers

It's possible that we're encountering spurious errors because changes in
the structure of exec.c and/or parse.c invalidate the wordcode in zcompile
output files, but that's not detected by autoload because the header only
contains $ZSH_VERSION (and not the patchlevel).

Originally this was done with the expectation that most people would need
to re-zcompile when installing a major new release, but maybe we should be
bumping along in smaller steps -- or at least have a mechanism for doing
some bumping when a wordcode-altering change is made?

See parse.c: write_dump() and load_dump_header(), though I can't think of
any simple way to automate such version-bumping (other than to just use
the full ZSH_PATCHLEVEL).


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Granularity of zcompile header magic
  2015-02-13  4:09 Granularity of zcompile header magic Bart Schaefer
@ 2015-02-13 10:24 ` Peter Stephenson
  0 siblings, 0 replies; 2+ messages in thread
From: Peter Stephenson @ 2015-02-13 10:24 UTC (permalink / raw)
  To: zsh-workers

On Thu, 12 Feb 2015 20:09:33 -0800
Bart Schaefer <schaefer@brasslantern.com> wrote:
> It's possible that we're encountering spurious errors because changes in
> the structure of exec.c and/or parse.c invalidate the wordcode in zcompile
> output files, but that's not detected by autoload because the header only
> contains $ZSH_VERSION (and not the patchlevel).
> 
> Originally this was done with the expectation that most people would need
> to re-zcompile when installing a major new release, but maybe we should be
> bumping along in smaller steps -- or at least have a mechanism for doing
> some bumping when a wordcode-altering change is made?

I think you're right: we should be more disciplined about updating the
number after the "dev" when making incompatible changes to the wordcode
(which aren't actually that common).  I don't think there's any
effective way of automating this with the way the wordode works --- it's
a question of adding or changing a word in the parser, then its use in
the execution code and its text decode.

pws


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2015-02-13 10:24 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-02-13  4:09 Granularity of zcompile header magic Bart Schaefer
2015-02-13 10:24 ` Peter Stephenson

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).