Hi guys,
Has anyone ever real heard of implementing type systems and
type inference on top of lisp as a kindof macro library?
I'm picturing something like
(with-hindley-milner
(rest-o-the-code))
Browsing a few pages of google search results I didn't find
anything to promising. Is this just a bad idea or not done
for some particular reason?
It isn't as simple as it seems, plus you do not want a macro layer.
You want something that allows you to work seamlessly with the system.
In any case, you need a unification system to do this :) CL-UNIFICATION
in common-lisp.net is a step in that direction.
Cheers
--
marco
Creighton Hogg wrote:
> Hi guys,
> Has anyone ever real heard of implementing type systems and
> type inference on top of lisp as a kindof macro library?
> I'm picturing something like
> (with-hindley-milner
> (rest-o-the-code))
> Browsing a few pages of google search results I didn't find
> anything to promising. Is this just a bad idea or not done
> for some particular reason?
On Thu, 29 Dec 2005, Marco Antoniotti wrote:
> It isn't as simple as it seems, plus you do not want a macro layer.
> You want something that allows you to work seamlessly with the system.
>
> In any case, you need a unification system to do this :) CL-UNIFICATION
> in common-lisp.net is a step in that direction.
Now I'm intrigued: why wouldn't you want a macro layer? In
my eye it would compile into a bunch of expressions that
call the type declarations of CL itself.
Hrmm...is it the fact that it would compile into statements
for the compiler that's the problem?
Well, maybe I spoke too fast. At a certain level you will have macros,
but they should be more of the kind
(defmacro typed-cl:defun (....) ...)
I.e. substituting the main definition forms etc. etc.
At least that is how I would set it up.
However, you still have the problems of dealing with CL type system
(which was not designed with a HM type checker in mind), with the
problem of run-time type checks and with the problem of run-time
redefinition of various things.
Cheers
--
Marco
On Thu, 29 Dec 2005, dominikus wrote:
> Maybe Qi (built on top of Lisp) is something for you that is worth
> looking at, see
>
> http://www.lambdassociates.org/
Actually this does look pretty interesting, thanks.
I'm not sure if it's exactly what I was thinking of or not,
but it's at least a start.
Drew McDermott has done this as part of his suite of Yale tools for
lisp. Have a look at the software documentation and software tools on
his page at http://cs-www.cs.yale.edu/homes/dvm/
Cheers,
Robert
"RPG" <·········@gmail.com> writes:
> Drew McDermott has done this as part of his suite of Yale tools for
> lisp. Have a look at the software documentation and software tools on
> his page at http://cs-www.cs.yale.edu/homes/dvm/
Checking out a few of the pages there, I came across this one about
CL's FORMAT:
http://cs-www.cs.yale.edu/homes/dvm/format-stinks.html
I think he has a good point there, and it seems to me that FORMAT is
extremely unlispy, even more so than loop (if such a comparison is
possible). On the other hand, I don't notice FORMAT's unlispiness
threatening to transform my Lisp programs into C evilness... so maybe
it's acceptable.
What are people's thoughts on this? Does anyone actually go out of
their way to avoid FORMAT?
David
--
David Trudgett
http://www.zeta.org.au/~wpower/
Fearlessness is the first requisite of spirituality. Cowards can never
be moral.
-- Mohandas Gandhi
On Fri, 30 Dec 2005, David Trudgett wrote:
> "RPG" <·········@gmail.com> writes:
>
> > Drew McDermott has done this as part of his suite of Yale tools for
> > lisp. Have a look at the software documentation and software tools on
> > his page at http://cs-www.cs.yale.edu/homes/dvm/
>
> Checking out a few of the pages there, I came across this one about
> CL's FORMAT:
>
> http://cs-www.cs.yale.edu/homes/dvm/format-stinks.html
>
> I think he has a good point there, and it seems to me that FORMAT is
> extremely unlispy, even more so than loop (if such a comparison is
> possible). On the other hand, I don't notice FORMAT's unlispiness
> threatening to transform my Lisp programs into C evilness... so maybe
> it's acceptable.
>
> What are people's thoughts on this? Does anyone actually go out of
> their way to avoid FORMAT?
I'm pretty novice at lisp still, but format is one of those
things I have to look up basically every time I use it. It
is pretty unintuitive, at least at first.
On 9339 day of my life Creighton Hogg wrote:
> Hi guys,
> Has anyone ever real heard of implementing type systems and
> type inference on top of lisp as a kindof macro library?
> I'm picturing something like
> (with-hindley-milner
> (rest-o-the-code))
> Browsing a few pages of google search results I didn't find
> anything to promising. Is this just a bad idea or not done
> for some particular reason?
http://www.cliki.net/TypeL
--
Ivan Boldyrev
Is 'morning' a gerund?