needing some Hugs

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

needing some Hugs

AntC
Is anybody still listening here?

I see the Hugs source distro is still around - vintage 2006, and there's somebody curated it on github.

I'm particularly looking for a version with TRex, but the github-curated version doesn't seem to include that(?)

Can anybody comment on how easy it is to compile Hugs (on Windows), compared to compiling GHC? The instructions for Hugs make out it's reasonably easy, whereas the instructions for GHC seem to be fraught with gotchas. But perhaps Hugs has as many gotchas, just not documented(?)

My impression from discussion forums when Hugs was still active, is that Hugs source was easier to hack if you wanted to experiment with changes to the language(?)

What seems sad these days is that GHC is so monstrous and formidable, hardly anybody builds experimental extensions to Haskell.

Thank you
AntC


_______________________________________________
Hugs-Users mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/hugs-users
Reply | Threaded
Open this post in threaded view
|

Re: needing some Hugs

Alex Dubov
 > On Thursday, 5 July 2018, 9:37:14 am AEST, Anthony Clayden <[hidden email]> wrote:

>
> >
> Is anybody still listening here?
>
> I see the Hugs source distro is still around - vintage 2006, and there's somebody curated it on github.
>
> I'm particularly looking for a version with TRex, but the github-curated version doesn't seem to include that(?)
>
> Can anybody comment on how easy it is to compile Hugs (on Windows), compared to compiling GHC? The instructions for Hugs make out it's reasonably easy, whereas the instructions for GHC seem to be fraught with gotchas. But perhaps Hugs has as many gotchas, just not documented(?)
>
> My impression from discussion forums when Hugs was still active, is that Hugs source was easier to hack if you wanted to experiment with changes to the language(?)
>
> What seems sad these days is that GHC is so monstrous and formidable, hardly anybody builds experimental extensions to Haskell.
>
> Thank you
> AntC
>

Back in a day, I wanted to build an embeddable Haskell interpreter for guile-like (or js-like) uses. And yes, hugs was way more approachable then GHC - it was mostly rather clear-cut  C code which was easy to rearrange and recompile.

But those days most people are on managed run-times anyway (be it jvm, clr or something js-based) and those can do scripting and extensions just fine as they are.

Regards,
Alex D
_______________________________________________
Hugs-Users mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/hugs-users
Reply | Threaded
Open this post in threaded view
|

Re: needing some Hugs

Neil Mitchell
In reply to this post by AntC
Hi Ant,

I don't believe anyone still maintains or uses Hugs - you'd be better
off looking at GHC.

Thanks, Neil

On Thu, Jul 5, 2018 at 12:37 AM Anthony Clayden
<[hidden email]> wrote:

>
> Is anybody still listening here?
>
> I see the Hugs source distro is still around - vintage 2006, and there's somebody curated it on github.
>
> I'm particularly looking for a version with TRex, but the github-curated version doesn't seem to include that(?)
>
> Can anybody comment on how easy it is to compile Hugs (on Windows), compared to compiling GHC? The instructions for Hugs make out it's reasonably easy, whereas the instructions for GHC seem to be fraught with gotchas. But perhaps Hugs has as many gotchas, just not documented(?)
>
> My impression from discussion forums when Hugs was still active, is that Hugs source was easier to hack if you wanted to experiment with changes to the language(?)
>
> What seems sad these days is that GHC is so monstrous and formidable, hardly anybody builds experimental extensions to Haskell.
>
> Thank you
> AntC
>
> _______________________________________________
> Hugs-Users mailing list
> [hidden email]
> http://mail.haskell.org/cgi-bin/mailman/listinfo/hugs-users
_______________________________________________
Hugs-Users mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/hugs-users
Reply | Threaded
Open this post in threaded view
|

Re: needing some Hugs

AntC

On Thu, 5 Jul 2018 at 8:29 PM, Neil Mitchell wrote:
Hi Ant,

Thanks for replying Neil.


I don't believe anyone still maintains or uses Hugs

Yes, that's what I was expecting.


- you'd be better off looking at GHC.

Why?

I mean seriously: if the docos for TRex are accurate, all that non-maintenance for Hugs has still produced a better records system than GHC has managed, in well over a decade.
GHC has some tweaks for records (FieldPuns and DisambiguateRecordFields and friends, also now DuplicateRecordFields).
But Trex would appear to have all that covered.

Vintage ~2006 Hugs (with extensions) was very comparable to GHC (with glasgow-exts).
There are some subtle differences in implementation of FunDeps and overlaps.
GHC's implementation is what I'd call wrong/contrary to the literature. (SPJ's word is "bogus".)
Hugs' implementation is more along the right lines.
GHC's behaviour today is the same as 2006. Clearly it's not going to be fixed.

GHC now has Type Families, which sometimes gives prettier code than FunDeps/overlaps.
But no more functionality AFAICT.

GHC has GADTs -- which I've never felt much use for.

GHC has PolyKinds and DataKinds and Type-in-type, whose main effect is to generate impenetrable error messages (even when I didn't think I was using those extensions).
(You can achieve DataKinds in Hugs with empty data decls -- see for example the HList paper.)

Then I'm struggling to see anything for which I'd be "better off" with GHC.
My experience from trying to contribute to the GHC design process
is that GHC is becoming more complex, more abstract, more obtuse, its Haskell syntax is uglier (like Perl), and no more useful.

The first extension since 2006 for which I see merit is the Quantified constraints.
(It's hard to be sure until it's released and I can get my hands on it.
 I have in mind uses that haven't appeared in the literature or Trac testing.
 And my questions/suggestions have gone unanswered.)
Note all the nutting-out for that was in an SPJ paper in 2000.

"unanswered" seems to be a recurring issue with GHC 'maintenance' which is why I'm questioning your "better off".
I seldom get answers to Stackoverflow q's or glasgow-users posts or cafe bright ideas.
So thank you again for replying here.

The features I'm looking for are clearly not going to happen unless I hack them myself.
(In particular something that was sketched in a paper in 2002.)
Hence my question here: I have a suspicion all that feature-bloat in GHC has made it harder to hack than it was in 2006. 
(And it seems it was already harder than for Hugs.)


AntC


On Thu, Jul 5, 2018 at 12:37 AM Anthony Clayden
<[hidden email]> wrote:
>
> Is anybody still listening here?
>
> I see the Hugs source distro is still around - vintage 2006, and there's somebody curated it on github.
>
> I'm particularly looking for a version with TRex, but the github-curated version doesn't seem to include that(?)
>
> Can anybody comment on how easy it is to compile Hugs (on Windows), compared to compiling GHC? The instructions for Hugs make out it's reasonably easy, whereas the instructions for GHC seem to be fraught with gotchas. But perhaps Hugs has as many gotchas, just not documented(?)
>
> My impression from discussion forums when Hugs was still active, is that Hugs source was easier to hack if you wanted to experiment with changes to the language(?)
>
> What seems sad these days is that GHC is so monstrous and formidable, hardly anybody builds experimental extensions to Haskell.
>
> Thank you
> AntC
>
> _______________________________________________
> Hugs-Users mailing list
> [hidden email]
> http://mail.haskell.org/cgi-bin/mailman/listinfo/hugs-users

_______________________________________________
Hugs-Users mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/hugs-users
Reply | Threaded
Open this post in threaded view
|

Re: needing some Hugs

Neil Mitchell
> Why?

Of course, your choice, merely relaying what is my advice.

> I mean seriously: if the docos for TRex are accurate, all that non-maintenance for Hugs has still produced a better records system than GHC has managed, in well over a decade.
> GHC has some tweaks for records (FieldPuns and DisambiguateRecordFields and friends, also now DuplicateRecordFields).
> But Trex would appear to have all that covered.

Yep, but Hugs doesn't have any modern libraries that work with it.

> GHC's behaviour today is the same as 2006. Clearly it's not going to be fixed.

I'm working to fix the GHC record behaviour :)

> "unanswered" seems to be a recurring issue with GHC 'maintenance' which is why I'm questioning your "better off".
> I seldom get answers to Stackoverflow q's or glasgow-users posts or cafe bright ideas.
> So thank you again for replying here.

That must be frustrating. All I can promise is you'll probably get
less support on Hugs. There are other Haskell compilers, Jhc, ajhc etc
that might be more alive than Hugs. Compiler hacking can be lonely!

Thanks, Neil

>>
>> On Thu, Jul 5, 2018 at 12:37 AM Anthony Clayden
>> <[hidden email]> wrote:
>> >
>> > Is anybody still listening here?
>> >
>> > I see the Hugs source distro is still around - vintage 2006, and there's somebody curated it on github.
>> >
>> > I'm particularly looking for a version with TRex, but the github-curated version doesn't seem to include that(?)
>> >
>> > Can anybody comment on how easy it is to compile Hugs (on Windows), compared to compiling GHC? The instructions for Hugs make out it's reasonably easy, whereas the instructions for GHC seem to be fraught with gotchas. But perhaps Hugs has as many gotchas, just not documented(?)
>> >
>> > My impression from discussion forums when Hugs was still active, is that Hugs source was easier to hack if you wanted to experiment with changes to the language(?)
>> >
>> > What seems sad these days is that GHC is so monstrous and formidable, hardly anybody builds experimental extensions to Haskell.
>> >
>> > Thank you
>> > AntC
>> >
>> > _______________________________________________
>> > Hugs-Users mailing list
>> > [hidden email]
>> > http://mail.haskell.org/cgi-bin/mailman/listinfo/hugs-users
_______________________________________________
Hugs-Users mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/hugs-users
Reply | Threaded
Open this post in threaded view
|

Re: needing some Hugs

Doug McIlroy
In reply to this post by AntC
I have little constructive to say on the topic, except
that I typically use hugs in preference to "monstrous"
ghc/ghci. It's lightweight and its language is properly
documented (in the Haskell 98 report), neither of which
can be said of ghc. Its rudimentary instrumentation
(:set +s) is more useful than ghc's equivalent, though
admittedly ghc has many debugging features I haven't
explored.

That said, it should be noted that I do not use
Haskell (nor, nowadays, any other language) for
writing production code.

Apropos of language, a couple of years ago I noted
that ghc implements 2^99 languages, not one. (There
were 99 non-antonymous language pragmas; there may
be more now.) Who can know what terrors lurk there.
My first attempt to investigate the field (turn on
all 99) caused a compiler panic, since fixed.

Early on, I encountered a hugs bug: garbage collection
in the middle of a bignum operation caused havoc.
Having never looked at the hugs source before, I was
able quite quickly pinpoint the offending code; the
maintainers corrected it almost overnight. That
heart-warming experience hasn't worn off, even though
the maintainers have moved on.

Doug
_______________________________________________
Hugs-Users mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/hugs-users
Reply | Threaded
Open this post in threaded view
|

Re: needing some Hugs

Simon Peyton Jones
|  ghc/ghci. It's lightweight and its language is properly documented (in the
|  Haskell 98 report), neither of which can be said of ghc.

I think that’s a little unfair to GHC 😊. If you don't give any language extension flags you get Haskell 98 -- or nowadays Haskell 2010.

Simon

|  -----Original Message-----
|  From: Hugs-Users <[hidden email]> On Behalf Of Doug McIlroy
|  Sent: 06 July 2018 15:04
|  To: [hidden email]
|  Subject: Re: [Hugs-users] needing some Hugs
|  
|  I have little constructive to say on the topic, except that I typically use
|  hugs in preference to "monstrous"
|  ghc/ghci. It's lightweight and its language is properly documented (in the
|  Haskell 98 report), neither of which can be said of ghc. Its rudimentary
|  instrumentation (:set +s) is more useful than ghc's equivalent, though
|  admittedly ghc has many debugging features I haven't explored.
|  
|  That said, it should be noted that I do not use Haskell (nor, nowadays, any
|  other language) for writing production code.
|  
|  Apropos of language, a couple of years ago I noted that ghc implements 2^99
|  languages, not one. (There were 99 non-antonymous language pragmas; there
|  may be more now.) Who can know what terrors lurk there.
|  My first attempt to investigate the field (turn on all 99) caused a compiler
|  panic, since fixed.
|  
|  Early on, I encountered a hugs bug: garbage collection in the middle of a
|  bignum operation caused havoc.
|  Having never looked at the hugs source before, I was able quite quickly
|  pinpoint the offending code; the maintainers corrected it almost overnight.
|  That heart-warming experience hasn't worn off, even though the maintainers
|  have moved on.
|  
|  Doug
|  _______________________________________________
|  Hugs-Users mailing list
|  [hidden email]
|  http://mail.haskell.org/cgi-bin/mailman/listinfo/hugs-users
_______________________________________________
Hugs-Users mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/hugs-users
Reply | Threaded
Open this post in threaded view
|

Re: needing some Hugs

AntC
Thanks Doug for your words of encouragement.

[Doug]
| | hugs in preference to "monstrous" ghc/ghci. It's lightweight ...

I agree in 'calculator mode', lightweight is a definite advantage.
It's a terrific way to ease into functional programming.
Haskell syntax of that era is aesthetically at the sweet spot between succinct-terse-cryptic-hieroglyphics-line noise.

| | and its language is properly documented (in the Haskell 98 report),

Hmm. My OP is clear I want Hugs 2006 with all extensions. So more than H98, indeed more than H2010.

| | neither of which can be said of ghc.

I think you're being over-generous to Hugs. Both Hugs and GHC document each feature individually.
The trouble is they don't document how features interact.
(Occasionally there's a 'grand unifying theorem', like OutsideIn(X). 
 I'm afraid the grand unifying type-in-type/path to Dependent Types is just too much for a bear of very little brain.)
So your point about 2^99 languages is well made.

Specifically for anonymous/extensible record systems, all of them
(TRex -- probably special hard coding, HList, Ur/web -- beyond Haskell but not extensible,
 endless libraries on Hackage -- mostly using TH boilerplate -- despite that mostly not extensible)
rely on the interaction of Overlaps and FunDeps -- hence the focus of my rant.
GHC's implementation is broken; Hugs just plays safe and disallows any interaction.

All the hip kids play in the lenses space. I guess they want their code to look like Perl or TECO, brogrammer style.
Sometime they'll discover why hierarchical data structures fell so badly out of fashion in the 1980's.


On Sat, 7 Jul 2018 at 2:46 AM, Simon Peyton Jones wrote:

I think that’s a little unfair to GHC 😊. If you don't give any language extension flags you get Haskell 98 -- or nowadays Haskell 2010.

Thanks Simon, but that's true only up to a point (Lord Copper).
I don't configure for pure H2010, see above. I do configure for a handful of extensions;
I do wish error messages didn't suggest all sorts of high-fallutin' things I might have meant when I merely made a typo.

GHC's syntax space is getting so crowded now that a typo is quite likely to get mis-parsed as trying to use some feature I didn't even know existed.
Then I appreciate Hugs doesn't confuse me with those possibilities.

Oh, and as Doug mentions in his follow-up message: Libraries. 
I get it that's strictly-speaking not within GHC's bailiwick.
I don't want all that abstruse category-theory shit.
I want `length` applicable to a List and only to a List. And not to throw messages about instances of Foldable.
So when Neil says "Hugs doesn't have any modern libraries " I'm seeing that as another benefit.

Yes I know I could opt for a simpler Prelude; I could override the type for `length`. 
I resent that casual users/newbies must jump through hoops to do that.
The onus should be on those who want fancy stuff to jump through the hoops -- for them it's not a burden.

Like Doug, I'm not aiming to produce production code.
Nor production-level mods to any compiler.

AntC


|  -----Original Message-----
|  From: Hugs-Users <[hidden email]> On Behalf Of Doug McIlroy
|  Sent: 06 July 2018 15:04
|  To: [hidden email]
|  Subject: Re: [Hugs-users] needing some Hugs

|  I have little constructive to say on the topic, except that I typically use
|  hugs in preference to "monstrous"
|  ghc/ghci. It's lightweight and its language is properly documented (in the
|  Haskell 98 report), neither of which can be said of ghc. Its rudimentary
|  instrumentation (:set +s) is more useful than ghc's equivalent, though
|  admittedly ghc has many debugging features I haven't explored.

|  That said, it should be noted that I do not use Haskell (nor, nowadays, any
|  other language) for writing production code.

|  Apropos of language, a couple of years ago I noted that ghc implements 2^99
|  languages, not one. (There were 99 non-antonymous language pragmas; there
|  may be more now.) Who can know what terrors lurk there.
|  My first attempt to investigate the field (turn on all 99) caused a compiler
|  panic, since fixed.

|  Early on, I encountered a hugs bug: garbage collection in the middle of a
|  bignum operation caused havoc.
|  Having never looked at the hugs source before, I was able quite quickly
|  pinpoint the offending code; the maintainers corrected it almost overnight.
|  That heart-warming experience hasn't worn off, even though the maintainers
|  have moved on.

|  Doug
|  _______________________________________________
|  Hugs-Users mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/hugs-users
_______________________________________________
Hugs-Users mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/hugs-users

_______________________________________________
Hugs-Users mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/hugs-users