Hacker News new | ask | show | jobs
by andrewflnr 4473 days ago
> everything will parse fine.

That's an exaggeration. There are circumstances in files where it's necessary. I didn't realize this, which hung me up for a long time.

2 comments

Would you care to share an example? I've never encountered a justifiable need to write ;; outside the REPL. The only uses of ;; I've encountered "in the wild" were hardly reasonable: essentially top-level code that was not wrapped in a "let () = ..." statement.
I don't recall seeing that recommendation before this thread. That may just be my blindness in skimming things too quickly. In any case, I think it indicates a wart in the language when you have to wrap everything in otherwise useless let blocks just to get it to parse.
Don't put non-let expressions at the top level?