[plt-scheme] [redex] extending languages

From: Casey Klein (clklein at eecs.northwestern.edu)
Date: Mon Jan 4 11:35:24 EST 2010

On Mon, Jan 4, 2010 at 10:21 AM, Robby Findler
<robby at eecs.northwestern.edu> wrote:
> On Mon, Jan 4, 2010 at 9:59 AM, Keiko Nakata <keiko at kurims.kyoto-u.ac.jp> wrote:
>> Hello,
>>
>> I am wondering what would be a recommended way to play with
>> extending languages in plt redex.
>>
>> When a language is extended with new constructs, then I need to extend
>> both the reduction-relation and associated metafunctions, such as one
>> for substitution. As a reduction-relation is extended,
>> rules inherited from the original reduction-relation should use
>> extended metafunctions. Similarly when a metafunction g, which may call
>> another metafunction f, is extended,
>> clauses inherited from original should call the extended version of f.
>>
>> Is this doable within redex facilities?
>
> Unfortunately, it is not, at the moment. Matthew had a nice suggestion
> about how to do this and it is on the list to be added to Redex, but
> it isn't there yet. Sorry.
>

Specifically, it's on the list here:

   http://bugs.plt-scheme.org/query/gnatsweb.pl?cmd=view&pr=10271

If you'd like, I'll add you to the PR's notification list.

>> Or, should/could I use PLT's unit system?
>
> I'm not sure if the unit system will actually be able to do this for
> you. If you try it and it doesn't turn out to work, the usual hack is
> to build some macros that expand into the language definitions you
> want to extend and use them to work around Redex's shortcomings.
>> [In short, I am facing the so-called expression problem.]
>
> The correct term is the "extensibility" problem. See:
>
>  http://www.cs.utah.edu/plt/publications/icfp98-ff/
>
> Robby
> _________________________________________________
>  For list-related administrative tasks:
>  http://list.cs.brown.edu/mailman/listinfo/plt-scheme
>
>


Posted on the users mailing list.