guile-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Can Guile be bootstrapped from source without psyntax-pp.scm?


From: Mark H Weaver
Subject: Re: Can Guile be bootstrapped from source without psyntax-pp.scm?
Date: Thu, 06 Jul 2017 21:42:47 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.2 (gnu/linux)

Hi Alex,

Alex Vong <address@hidden> writes:

> Recently, I've read the chapter on Macros in Guile's manual. The manual
> says that Guile's expander originated from that of Chez Scheme's and
> that version was portable to other schemes as well. So I search the
> Internet and find it[0]. The website states that the expander needs an
> expanded version of itself for bootstrapping, i.e. psyntax.ss needs
> psyntax.pp for bootstrapping.
>
> After playing for awhile, I realize the relationship of Guile's
> psyntax.scm and psyntax-pp.scm is exactly analogus. One needs an
> expanded version of psyntax.scm, i.e. psyntax-pp.scm for bootstrapping.
>
> Does this mean Guile is not bootstrappable from source only?

That's correct.  psyntax-pp.scm is not source code, and it is needed to
bootstrap Guile.  However, I made an effort some years ago to make
psyntax-pp.scm far smaller and more readable than the corresponding file
from upstream psyntax.  See:

  
https://git.savannah.gnu.org/cgit/guile.git/commit/?h=stable-2.0&id=72ee0ef71b9a0514874976cdcf3ea9d5333db4b1
  
https://git.savannah.gnu.org/cgit/guile.git/commit/?h=stable-2.0&id=1af6d2a717f499564fbbc297c79e00ac14b0dcf9

At this point, I believe it would be quite feasible for a single hacker
to audit our psyntax-pp.scm and compare it to psyntax.scm within a
reasonable time frame.  Furthermore, when we make local changes to
psyntax.scm, the corresponding changes to psyntax-pp.scm are localized
and quite easy to audit as well, so the full audit need not be repeated.

Having said this, I agree that it would be better if psyntax.scm were
written in such a way that it could be bootstrapped without the use of
itself.  Maybe some day we'll rewrite it to make it so.

      Mark



reply via email to

[Prev in Thread] Current Thread [Next in Thread]