Advertisement · 728 × 90

Posts by Basile Henry

That is pretty messed up 🤯
So if you go sail around the world you better be back under 3 years?

3 days ago 0 0 1 0

In all seriousness, I don't know anything about boat VAT in the EU and I understand it might be messed up even if you don't own/plan on owning one 🤔

3 days ago 0 0 1 0

Why do you care about VAT on boats if you don't have any? 😅

3 days ago 0 0 1 0

Is that... one of the rare use cases for a bloom filter? 🤔

3 days ago 1 0 1 0

Maybe you could have a go to definition for the impl function itself go to the class definition? 🤔 So from any use site you're one hop away from 2) and two hops away from 1)

2 weeks ago 1 0 0 0

I'm pretty sure there will always be something more useful to spend the energy on, even if highly inefficient, like desalination 🤔

3 weeks ago 0 0 0 0

With Nat you can encode constraints without extra comparison support:

head :: Vec (n + 1) a -> a

But if you support comparison constraints I think this is nicer to use in practice anyway:

head :: (1 <= n) => Vec n a -> a

1 month ago 4 1 0 1

Is that because for B you could take a reference to b.1 and the layout has to match (u8, u16)? 🤔

1 month ago 1 0 1 0
Advertisement
Preview
Careers We are always looking for brilliant minds to join our team. If you have experience in Computer Science, Maths, or ML, we’d love to hear from you!

You could learn Haskell while employed: myrtle.ai/about/careers/ 😄
We use Rust, Haskell, nix (and Python, Verilog, ...) for compilers and customs FPGA circuits

2 months ago 3 0 0 0

So maybe we should be vibe coding in C to be consistent in our use of UB throughout the abstractions 😅

2 months ago 1 0 0 0

Probably a rhetorical "what" 🤔

It basically says that `[a]` is equivalent to a function `Int -> a`.

It's effectively the indexing function. If you want to set a value in the "array", you create a new function that checks if the input is the index you're setting and use the old function otherwise.

3 months ago 2 0 0 0
Home

Lots of GADTs when writing Clash Haskell 😭

clash-lang.org

4 months ago 1 0 0 0

"Linux in the Kernel" 👀 How dare they! 😅

4 months ago 9 0 0 0

That is a pretty bad error message 😅 I assumed the Generic instance was a given and was already reaching for orphan instances to explain the lack of import
bsky.app/profile/basi...

4 months ago 0 0 0 0

Maybe you're also supposed to derive Generic for that type in the shame module (so it's not an orphan instance), and that would force you to add the import 🤔

4 months ago 0 0 0 1

Ouch 😬 That would make sense to me for TemplateHaskell generated code, but for this type of instance deriving/default impl it feels like the extension should manage its own imports 😅

4 months ago 0 0 1 0

M1 not in scope is weird 🤔 missing a language extension?

4 months ago 1 0 1 0
Advertisement

I don't know how much AI they ended up using, but watching some of their dev talks a while ago they had some really impressive procedural generation using advanced ML techniques (i.e. AI), it really didn't strike me (at that time) like the plagiarism machine you hear about in more recent game dev 🤷‍♂️

4 months ago 1 0 0 0

Nice example! 😊

4 months ago 1 0 0 0

I mean yeah theoretically 😅 It's a practical approach, and I'm struggling to find ways to exploit it to create a function that would do radically different things for different types 🤔
There might be some tricks where you detect the type using broken `==` for NaN, but that's also the case in Haskell

4 months ago 1 0 1 0

I think it might depend if you have "magic" (no constraints) type classes à la Elm for things like `==`, `+`, or `>=` 🤔

4 months ago 1 0 1 0

That's probably the most reliable method (especially since the source path could be generated from nix)!
I guess I'm not trusting my AI enough to do the run build step for me yet 😅

5 months ago 1 0 0 0

That's much better! 😊 What's the workflow like? Does it get the hash locally?

5 months ago 0 0 1 0

It'd be impressive if AI could guess the hashes 😅

5 months ago 0 0 1 0

Maybe the lock file could keep the previous version info 🤔 Then for this specific issue, I don't think you need a full compilation of the previous version, only a way to track the impls back to the previous version (if they exist)

6 months ago 0 0 0 0

It feels like the type of issue that could be fixed automatically (annotate using the impl pre-upgrade) 🤔

6 months ago 1 0 1 0

How else would you know that the bread is Not a a Number 😅

10 months ago 3 0 0 0
Advertisement

O(n^2) for a naive compiler, O(1) for a decent compiler even with non-const n. With that inner loop's body, a good compiler could rewrite the snippet:
total = n*n
Although this assumes `n` is positive and has to consider `total`'s overflow semantics, which may not be reasonable in some languages 😅

11 months ago 0 0 0 0

Now we need a language where escaping a newline character is an alternative way to input the 'n' character 😈

11 months ago 2 0 0 0

Wordle 1,421 3/6

⬜⬜🟩🟨🟨
⬜⬜⬜🟩🟨
🟩🟩🟩🟩🟩

Got lucky with my 2 starting words 😊

11 months ago 1 0 0 0