this post was submitted on 11 Aug 2024
0 points (50.0% liked)

Gleam

129 readers
1 users here now

A community for the gleam programming language! https://gleam.run/

founded 2 years ago
MODERATORS
 

The blog post is the author's impressions of Gleam after it released version 1.4.0. Gleam is an upcoming language that is getting a lot of highly-ranked articles.

It runs on the Erlang virtual machine (BEAM), making it great for distributed programs and a competitor to Elixir and Erlang (the language). It also compiles to JavaScript, making it a competitor to TypeScript.

But unlike Elixir, Erlang, and TypeScript, it's strongly typed (not just gradually typed). It has "functional" concepts like algebraic data types, immutable values, and first-class functions. The syntax is modeled after Rust and its tutorial is modeled after Go's. Lastly, it has a very large community.

top 3 comments
sorted by: hot top controversial new old
[–] monogram@feddit.nl 1 points 4 months ago

Compatibility with JavaScript is atrocious

[–] lung@lemmy.world 0 points 1 year ago (1 children)

Doesnt seem particularly better than Go, unless you count compiling to JS as a strong need (knowing the JS world, I have my doubts on how useful/convenient that is until webasm really is adopted)

[–] monogram@feddit.nl 0 points 4 months ago

GoLang footguns:

  • handling of nil pointers
  • verbose if err is nil all because it doesn’t have a good stack trace
  • lack of enums

Even typescript has a better type system than golang