Hacker News

privong
Racket v9.3 blog.racket-lang.org

pavpanchekhaa day ago

I do a substantial amount of coding in Racket, including maintaining the Herbie numerical compiler (https://herbie.uwplse.org/) over the last decade.

Racket is great! The runtime is reasonably fast, and the standard library is exceptionally featureful, including, for example, a decent plotting library, an HTTP server, decent HTML and JSON support, several forms of multi-threading, and a quite good FFI, all of which Herbie uses extensively. I suppose the parentheses are a question of taste (I like them!) but a lot of the specific syntactic decisions, like the `for` and `match` macros, are quite nice.

summaritya day ago

Thank you for Herbie btw, it continues to be one of the most used tools in my personal projects (all 3D math and rendering)

akoboldfryinga day ago

What a neat tool, I had no idea such a thing existed!

whateveraccta day ago

the runtime is chez, right?

samth13 hours ago

Yes, Racket is built on top of Chez (there's a legacy mode with its own runtime but that's not very important).

salsa_catsupa day ago

Is Racket the Lisp where I wanted to write keywords like `foo:` or `:foo`, but they went with something like `'#:foo`, which ruined keyword syntax for me?

soegaard18 hours ago

Fear not, you can make `#%top` and `#:app` rewrite `foo:` to `#:foo`.

FWIW choosing `#:foo` over, say, `foo:` was due to backwards compatibility. In Scheme and Racket `foo:` is a legal identifier, so there might have been programs that stopped working, if `foo:` suddenly was a keyword.

tmtvla day ago

I don't know about Racket, but I do know Guile does that and I kind of prefer it as a way to reduce syntax (because the number sign is syntax already for most Lisps as the marker for a vector, and it's also used to bring functions into the symbol namespace in a Lisp-2) by freeing the colon.

everforward19 hours ago

Do they do something neat with the colon? I do prefer the shorter keyword syntax, at least in Clojure because of how common they are.

Clojure tends to use them very heavily though, and last I looked it seemed like Racket used more lists (as a matter of community preference, not forced by the language).

tmtvl10 hours ago

A colon in Guile is just a regular character. For example:

  (define abc:def 3)
  (define :ghi 4)
  (* abc:def :ghi) ; => 12
In Common Lisp a colon is a package separator, with an optional package which defaults to the keyword package if not given.

  (eq :foo keyword:foo) ; => t
I don't know about Clojure or Racket because I don't know much about Clojure or Racket. I know Clojure differs in various ways where syntax is concerned to Common Lisp or Scheme (I do like the idea of using square brackets to visually indicate that a collection of atoms may not represent a function call, I hate the idea of the comma being a whitespace character) and that Racket has different languages (though I don't know what that means in practise).

That said, I don't quite know what to think of your third sentence:

> Clojure tends to use them very heavily though, and last I looked it seemed like Racket used more lists

I suppose them refers to keywords? But Racket uses more lists compared to how much Clojure uses keywords? As lists have more uses than keywords that seems likely, though as I said: I don't know anything about Clojure or Racket apart from Racket once being called PLT Scheme.

shawn_w9 hours ago

Guile keywords use the same #:foo syntax as Racket. The reader can also accept :foo or foo: notation.

https://doc.guix.gnu.org/guile/latest/en/html_node/Keyword-R...

packetlost16 hours ago

Racket's lineage in Scheme is probably the reason it prefers lists over pretty much every other datastructure

pjmlp14 hours ago

Scheme has had all major data structures for quite some years now.

soegaard14 hours ago

Notice that Racket now supports "tree lists".

https://docs.racket-lang.org/reference/treelist.html

pmkarya day ago

I have heard so many bas thing about Racket, all the bullying of the core team and being really bad people in general. Each time I like to give it a shot I remember this and just walk away.

iainctduncan19 hours ago

Racket is made by academics. Academics piss on each other a lot, it's unfortanately part of the culture and has (historically) been rewarded in the system (I am a PhD candidate, FWIW, and so have many, many friends "in the system").

If you're going to get excited about academics being pissy and condescending to their rivals, you're going to eliminate an awful lot of useful things from your life when you peek behind the curtain at the conversations between the makers.

Personally, I find academic pissing matches far, far less offensive than the self-agrandizing bullshitting we find in industry. Look hard enough, and there are people being at least occasional jerks everywhere.

jambutters20 hours ago

What? I know what you're taking about but it's literally only 1 dude(Matthias vs Butterick) who has chilled down for the most part Everyone else is fine. Do you have the source for others being toxic?

moron4hire21 hours ago

I have never heard of this. Not saying it doesn't exist, I don't know what it's like to get involved as a maintainer, but as a regular user just asking questions on the mailing list, I never received any abuse.

spdegabrielle2 hours ago

I can't speak for others but the Racket management, maintainers and community are some of the kindest most patient people you will ever meet. Putting up with my dumb questions for many years now. (I'm not an academic)

On top of this they have maintained an open source project for 20+ years _as volunteers_.

hn-front (c) 2024 voximity
source