Haskell Community [Unofficial]
@discourse.haskell.org.web.brid.gy
6036 documents discourse.haskell.org
View on Bluesky
Mutation Testing in Haskell

From how I read Jello_Raptor comments on Announcing Mutation Testing in Haskell the library just surfaces these untested situations for you, it’s up to you to deal with them. The immediate goal here is to improve the test suite, which presumably will eventually improve the quality of the code[0]. I’ve done lots of minor “manual mutation testing” to ensure a new test covers a bugfix, so I do see…

Is there a way to get a OsChar literal more conveniently than osp + head

Keep in mind that OsChar is actually more or less a byte in an encoded byte sequence. You could argue it should have been named OsWord to avoid confusion.

There are cases where extracting an OsChar and pattern matching on it makes sense, e.g. notably with the filepath separator /, because it is encoding agnostic. But in other cases you may get nonsensical results if you expect…

Read more →
Mutation Testing in Haskell

andremarianiello:

The question is: does this mutation cause a change in behavior that is caught by a test?

Why should I care?

The basic assumption seems to be that a test suite must fail if the code is altered semantically.
Suppose there are two data types, A and B and a function f :: A -> B that is to be tested. Suppose both A and B are finite with n and m total elements,…

Read more →
Mutation Testing in Haskell

A test suite for test suites, is it?

How can I tell that a mutation is

  1. indeed of undesired behaviour,
  2. sufficiently distinct from the original that it deserves its own test case?

Especially with AI-generated code, I venture that mutation might actually have a chance of improving the code. Isn’t that what genetic algorithms were about?

Haskell distro packaging channel on Matrix

I wanted to announce that since early Feb 2026 we have a matrix room for people involved in distribution packaging of Haskell:

Haskell distro packaging

#haskell-distros:matrix.org

Please join if you are interested (already a number of distros are represented: Arch, Fedora, Nixpkgs, OpenSUSE, and Stackage (a source distro))

matrix.to

You're invited to talk on Matrix

You're…

Read more →
Is there a way to get a OsChar literal more conveniently than osp + head

I was making a small script that would remove all blank characters before a newline. i was unable to find a robust way to identify binary files so i decided to whitelist extensions.

I have a list of extensions without the dot and i needed to get a OsChar for the dot to use cons on each extension.

With a fresh mind i reconsidered my options and had a second look over filepath and found…

Read more →
Final call for GHC String Interpolation proposal!

Previous topic: Updates for String-related GHC proposals - #27 by brandonchinn178
HIW slides: GHC String Interpolation

After getting positive reception from my talk at HIW this week, and seeing as discussion has died down on the proposal, this will be the final call for review for the proposal, before I submit it to the committee. Thanks!

Serokell’s Work on GHC: Dependent Types, Part 5

AntC2:

Is there a risk of confusing the kind -> with a ViewPattern?

Yes. Tried initially in 9.10 with no extensions

ghci> let f ((+ 2) -> x) = x in f 7
    Illegal view pattern; suggest enable the extension [correct, same reporting as prev GHCs]

— instead :set -XRequiredTypeArguments; try same input
    error: [GHC-72516] Parse error in pattern: +2

— Ok, :set…
Read more →
[ANN] dnsbase 1.0: a flexible successor to the "dns" library

If you write DNS-related code in Haskell — or have been thinking about it — there’s a new library on Hackage that may be worth a look: dnsbase 1.0.2.0.

dnsbase is a DNS stub-resolver library. Its IO layer is derived from Kazu Yamamoto’s dns package, and the basic lookup interface — lookupA, lookupMX, lookupTXT, … — is deliberately similar, so migration is straightforward for anyone already…

Read more →
Looking for a parsec maintainer to assist with GHC 9.14 compatibility (is this package still actively maintained?)

jonathanknowles:

It seems like the process expects these changes to be propagated back at release time, and that this step was missed for GHC 9.14.1. Is that right?

No, it seems a GHC maintainer (@bgamari) opened a PR against the parsec repository well in advance of the 9.14.1 release: Bump base upper bound to <4.23 by bgamari · Pull Request #193 · haskell/parsec · GitHub

I don’t know…

Read more →
"I built a web language with Haskell-like syntax for fun.

That’s an interesting direction I hadn’t considered. Interpolating is technically separable from Haskell evaluation; it’s really just a matter of parsing the boundaries between HTML and embedded expressions. With Megaparsec, you could probably abstract it into a generic interface with its own built-in evaluator. I’m not sure how clean it would be in practice, but it’s worth exploring. Would you…

"I built a web language with Haskell-like syntax for fun.

Looks Cool!

I was wondering, how hard would it be to cut out the PHP-style parsing of HTML interleaved with code into some standalone reusable functionality? I assume people would love to plug in various custom other ad-hoc DSLs into this scheme.

(I guess there’s a lot of gotchas, mainly syntax collisions with the magic brackets, but perhaps there’s some unexplored design space there.)

Call for proposals: Reviewing, testing, and managing LLM generated Haskell

Haven’t seen Grace mentioned here:

github.com

GitHub - Gabriella439/grace: A prompt engineering functional programming...

A prompt engineering functional programming language

Beyond agentic coding with Grace (w/ Gabriella Gonzalez)

My favorite YouTube Haskeller Impure Pics had a great video about it. VERY interesting. I like the idea of guardrails on LLM’s and Grace achieves that quite…

Read more →
H2JVM - A Haskell Library for writing JVM Bytecode

The intention is that you can still manually write the desugared instructions if you need to (I can’t think of many situations where you’d need/want to right now though), so there will always be that escape hatch available. Though that’s a very all-or-nothing approach. I think you’re right though, and it probably should be the only option. Thanks again for the feedback.

H2JVM - A Haskell Library for writing JVM Bytecode

I wouldn’t mind that, but I am the one who suggested it. If anyone has a compelling reason, you could offer the less-safe API as an escape hatch. But some form of recursive do notation has been around for a long time. mdo was added in GHC 6.0 (May 2003), deprecated in 6.12.1 (December 2009) when rec was added, and then resurrected in 7.6.1 (September 2012). So I think it’s safe to say…

Looking for a parsec maintainer to assist with GHC 9.14 compatibility (is this package still actively maintained?)

hasufell:

This looks like an error in the GHC release process.
@wz1000 bumped this in the GHC submodules.

Thanks for the pointer @hasufell.

It does seem that GHC’s GitLab mirror of parsec has the following two commits:

  • branch ghc-9.14 with commit 552730e2 (bump base to <4.23)
  • branch ghc-10.0 with commit 15f8a710 (bump base to <4.24)

AFAICT neither of these branches…

Read more →
H2JVM - A Haskell Library for writing JVM Bytecode

That’s fair, for appending single instructions it’s probably worse, although I haven’t benchmarked. I think it should be better when you can append chunks of several instructions, so that it works like a builder.

The more important thing imo is to avoid the possibility of a “sign error” by putting <> in a natural order, and reverse-list also helps with that.

[ANN] tricorder - a new development tool for Haskell and LLMs

Does it mean that it tries to use multiple home units by default?

Yes, that’s correct!

The executable this creates is called tricorder-exe. Perhaps it should be simply tricorder?

Whoops! I just released version 1.0.0.1 that is actually called tricorder. Thanks for catching it!

Have you tried running it for an existing project? I’m at ZuriHac and found a case where a module using a…

[RFC] Sibyl: Time Series Analysis in Haskell

Bumping this thread for ZuriHac 2026.

I am planning to start up work on Sibyl again (I got super bogged down with university work) after ZuriHac ends and are currently wondering if it would be possible to get an idea of how people feel about time series work in Haskell. If you’re a data scientist or statistician – please, please comment as to how a library like this would save you time.

Sibyl,…

Read more →