Live data from Hacker News

Frege – a Haskell for the JVM

github.com

1–10 of 51 posts

Re: Frege – a Haskell for the JVM

#3

Interesting; any Haskell users comment on how portable code is between pure Haskell and Frege?

The below is the projects own take on that question:

"Frege gives you the opportunity to use your skills on the JVM. Most idiomatic Haskell code will run in Frege unmodified or with only minimal, obvious adaptions. Even more important: you can bring your purely functional problem solution strategies to your Java projects."

Re: Frege – a Haskell for the JVM

#5
post #3

Interesting; any Haskell users comment on how portable code is between pure Haskell and Frege?

The below is the projects own take on that question: "Frege gives you the opportunity to use your skills on the JVM. Most idiomatic Haskell code will run in Frege unmodified or with only minimal, obvious adaptions. Even more important: you can bring your purely functional problem solution strategies to your Java projects."

This is ridiculously optimistic. Perhaps many toy programs can be easily converted, but real programs that use libraries other than base will not be so easy to migrate.

I've used the Haste compiler which IS Haskell that supports ALL GHC extensions except TemplateHaskell, supports the Cabal build tool and in practice it has its own ecosystem; most of Hackage will not compile on it.

Frege doesn't implement all the language extensions (very commonly used ones, such as MultiParamTypeclasses, are not supported), it doesn't share a build tool. It would be a great deal of work to port any non-trivial program.

Re: Frege – a Haskell for the JVM

#6
post #5
post #3

Earlier quoted context omitted.

The below is the projects own take on that question: "Frege gives you the opportunity to use your skills on the JVM. Most idiomatic Haskell code will run in Frege unmodified or with only minimal, obvious adaptions. Even more important: you can bring your purely functional problem solution strategies to your Java projects."

This is ridiculously optimistic. Perhaps many toy programs can be easily converted, but real programs that use libraries other than base will not be so easy to migrate. I've used the Haste compiler which IS Haskell that supports ALL GHC extensions except TemplateHaskell, supports the Cabal build tool and in practice it has its own ecosystem; most of Hackage will not compile on it. Frege doesn't implement all the lang…

True, this "ecosystem" is often overlooked.

The goal of the Frege developers is to achieve full Haskell 2010 compatibility by the end of this year. However, that still doesn't mean you can port all code easily.

What it does mean is that you can use your Haskell skills in projects that are for some reason restricted to the JVM.

Re: Frege – a Haskell for the JVM

#8
Is writing "pure" Haskell to be hosted in a non-Haskell imperative environment a common thing to do, as opposed to separating the pure and the imperative via monads? Seems to me that Frege could make this quite attractive.

Re: Frege – a Haskell for the JVM

#10
post #8

Is writing "pure" Haskell to be hosted in a non-Haskell imperative environment a common thing to do, as opposed to separating the pure and the imperative via monads? Seems to me that Frege could make this quite attractive.

I fail to understand the question. Isn't hosting "pure" Haskell code in an imperative modern OS environment a common thing to do?
Post reply on HN