Hacker News new | ask | show | jobs
by foobazgt 229 days ago
Slava mentions both bidirectional inferencing and overloading as two of the big culprits.

I've been doing some language work recently, and I'm quite sympathetic to bidirectional inferencing. I think, though, that modern PLs need better solutions for adhoc overloading. It's notorious for its complexity, blowing up algorithmically, and confusing users with surprising results (why oh why did the compiler select this function over the one I intended). That said, I haven't discovered a good alternative (for my purposes) yet.

2 comments

The paper The Simple Essence of Overloading: Making Ad-Hoc Polymorphism More Algebraic with Flow-Based Variational Type-Checking, should help with the overloading part hopefully
> I think, though, that modern PLs need better solutions for adhoc overloading.

So, something like "How to make ad-hoc polymorphism less ad hoc"?

Orphanless typeclasses FTW