guile-devel
[Top][All Lists]
Advanced

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

Re: Some guile-unify activities


From: Stefan Israelsson Tampe
Subject: Re: Some guile-unify activities
Date: Mon, 9 May 2011 13:15:10 +0200

Hmm, type annotations in typed racket is defined according to

http://docs.racket-lang.org/ts-guide/more.html#%28part._.Type_.Annotation_and_.Binding_.Forms%29

Any objections against that scheme? ideas?

A suggestion would be to have a type item in tree-il that works like
(<type> type _expression_)

And at first stage let tree-il->glil code just ignore this information.

For <let>  tree-il code  we could just use the method
(let ((x : number 1)) code)
-->
(<let> ((<type> number x)) (1) code)

For lambda expressions we could use
(lambda ([x : integer]) : symbol code)

as

(<lambda> ((<type> integer x)) (<type> symbol code))

So, a first step would be to enter a type tree-il record and then make sure that various tree-il->* translators can
use them (ignoring them at first). modify scheme->tree-il  to allow typeed variants, and also enter a (type x) form
directly.

What do you think?


On Sun, May 8, 2011 at 5:52 PM, Andy Wingo <address@hidden> wrote:
Hi Stefan,

Thanks for this mail, it's interesting.

On Fri 06 May 2011 23:18, Stefan Israelsson Tampe <address@hidden> writes:

> It would be good if there was a standard way to enter type information
> in guile and if that information could be hooked into the tree-il
> representation. But until then I will just use a simple macro
> framework to enter typed functions.

Agreed, that this would be good.  Something to think about for 2.2.

Happy hacking,

Andy
--
http://wingolog.org/


reply via email to

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