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

Macro in teachpack



Hi everyone,

I need to put a macro into a teachpack.

I would like to place my own streams definition and parallel constructs to
teachpacks and give them to the students so they can work with them without
any need to load and execute additional files.

Is there anyone who could guide me in this process? Or is it just a bad idea
to do it this way?

Thanks for any response.

David.


-----------------------------------------------
David Skoupil
Palacky University
skoupil@upol.cz
www.inf.upol.cz/~skoupil


----- Original Message -----
From: "Matthew Flatt" <mflatt@cs.utah.edu>
To: "Trevor Clarke" <trevor@notcows.com>
Cc: <plt-scheme@fast.cs.utah.edu>
Sent: Wednesday, June 06, 2001 10:24 AM
Subject: Re: byte code format


> Quoting "Trevor Clarke":
> > Could someone point me to some information about the format of the
> > byte code in a .zo?
>
> There is none (other than the source, as you point out).
>
> A .zo file is essentially a compacted S-expression. The details are
> complex, including a hash table for symbols (i.e., the first instance
> of a symbol is encoded as a index--symbol pair, and later instances
> just use the index), a vector-like representaton for lists, index-based
> references to primitives, and various S-expression encodings of
> primitive syntactic forms. Furthermore, the details change fairly
> often, either because the primitive indices shift when a new primitive
> is added, because I notice a new trick to make bytecode files more
> compact, or because a new kind of literal is added. As an example of
> the last reason, the v200 format is greatly complicated by the presence
> of syntax objects.
>
> The S-expression encoded in a .zo file, in turn, is an encoding of a
> (fairly small) set of records representing the actual bytecodes that
> MzScheme executes. Those records do not change very often, though they
> can be somewhat complex (e.g., the record representing a module
> declaration) and they are very much tune d to the evaluator's
> achitecture.
>
> So, unfortunately, the .zo format is not remotely friendly as a medium
> for getting MzScheme version XYZ code to anywhere other than MzScheme
> version XYZ.
>
> Matthew
>
>