Conversation

I’m always silly and end up confusing cycles in my modules and messing up my own intended design. Crates are a nice way to prevent that, but it’s heavy weight, and forces you to expose internal architectural decisions to the package ecosystem.
1
2
Yeah crates are obviously too heavy for this purpose. I was just surprised because I don't think "I wish I could have prevented myself from accidentally calling this function mutually-recursively" is a problem I've ever (noticed & remember that I) had.
1
Oh I see -- your issue isn't so much with (mutually) recursive functions, but with recursive modules/imports. (IIRC, SML and/or OCaml have explicit control over *both* of these things?)
1
1
I understand that better. I do have the intuition that modules and packages should "behave the same" (I'm reaching for a word, which might be "scale-invariance"?). OTOH, *not* having recursive modules can also be supremely annoying (Haskell, I'm looking at you).
2
1
Replying to
If I had a dollar for every time I tried to look at an interesting-seeming Haskell project on github, discovered it was a nest of re-re-exports with the actual code scattered somewhere out in the leaves, and gave up, I'd have several dollars.
2