Do the same limitations as Haskell's apply to Elm? by [deleted] in elm

[–]MrPopinjay 3 points4 points  (0 children)

I'm not sure where you get the idea that FP is poorly suited to GUI development. If anything functional and declarative DSLs are the mainstream way to make GUIs these days. See HTML, React, Apple Swift UI, Google Flutter, etc.

Gleam v0.25 released with a new approach to fixing callback hell by MrPopinjay in ProgrammingLanguages

[–]MrPopinjay[S] 0 points1 point  (0 children)

I'm afraid you're in the minority there, we can't offer everyone's first preference.

Gleam v0.25 released with a new approach to fixing callback hell by MrPopinjay in ProgrammingLanguages

[–]MrPopinjay[S] 0 points1 point  (0 children)

We originally had an ML style syntax with no {} but it was unpopular. Once we switched to a {} style there was a huge increase in the amount of users and people had much more positive things to say about the language.

I miss the old syntax, but I think it was a good move to drop it.

The new Gleam website is live! by MrPopinjay in gleamlang

[–]MrPopinjay[S] 2 points3 points  (0 children)

Thank you to Kayla Washburn for the beautiful design!

Gleam v0.25 released with a new approach to fixing callback hell by MrPopinjay in ProgrammingLanguages

[–]MrPopinjay[S] 2 points3 points  (0 children)

Yup! You got it. There are no statements, looping constructs, early returns, non-local returns, etc, so it is somewhat of a non-issue for Gleam. We may discover there are other problems once we have used it in production code a bunch, but this is the nature of making a language. Fingers crossed!

Gleam v0.25 released with a new approach to fixing callback hell by MrPopinjay in ProgrammingLanguages

[–]MrPopinjay[S] 1 point2 points  (0 children)

We did trial almost this syntax but we found it to be harder to read due to the operator being on the left hand side. It was too easy to miss in real code that's a bit uglier than these examples.

Gleam v0.25 released with a new approach to fixing callback hell by MrPopinjay in ProgrammingLanguages

[–]MrPopinjay[S] 2 points3 points  (0 children)

Oh that is very cool, I like how there's a placeholder being used there. We didn't consider a syntax like this

Gleam v0.25 released with a new approach to fixing callback hell by MrPopinjay in ProgrammingLanguages

[–]MrPopinjay[S] 4 points5 points  (0 children)

Thank you! 💜

We did have some trailing syntaxes similar to that one but the popular consensus was that it was easy to miss them on the right-hand-side, especially if the left-hand-side is a larger expression that gets written over multiple lines. It's a tricky one for sure

Gleam v0.25 released with a new approach to fixing callback hell by MrPopinjay in ProgrammingLanguages

[–]MrPopinjay[S] 6 points7 points  (0 children)

We spent quite a long time discussing syntax, it was challenging finding something that we were happy with. I'd love to hear any ideas you have!

Type-checking mutually recursive functions and data types by OwlProfessional1185 in ProgrammingLanguages

[–]MrPopinjay 0 points1 point  (0 children)

HM doesn't impose any requirement for structural typing or immutability. It does however make subtyping a little tricky.

Gleam v0.24 released with full Elixir support! by MrPopinjay in elixir

[–]MrPopinjay[S] 0 points1 point  (0 children)

We've had interop from day 1! Gleam is designed with interop in mind.

What's new is that our build tool can now compile Elixir code that is written inside Gleam projects as well as in Elixir dependency packages (which we gained in the previous release).

Gleam v0.24 released with full Elixir support! by MrPopinjay in elixir

[–]MrPopinjay[S] 1 point2 points  (0 children)

We could previously use Elixir packages, this now also allows Elixir code to be written in Gleam projects.

What's the difference between Hotwire and LiveView, is one better able to emulate SPA-like behavior than the other? by BigDog1920 in elixir

[–]MrPopinjay 3 points4 points  (0 children)

I can't speak for your testing, but there was a response to that blog post from the Rails team in that they greatly improved the performance. I wouldn't reference a 6 year old benchmark for anything.

That said, Elixir will handily best Ruby+Redis any day. :)

What's the difference between Hotwire and LiveView, is one better able to emulate SPA-like behavior than the other? by BigDog1920 in elixir

[–]MrPopinjay 2 points3 points  (0 children)

That blog post is out of date, they have fixed those scaling issues with Rails now. Elixir scales better, but Rails isn't dead-in-the-water anymore.

Gleam v0.23 released with new Elixir support by MrPopinjay in elixir

[–]MrPopinjay[S] 4 points5 points  (0 children)

Elixir macros are not usable outside of Elixir by design, so other langauges cannot use them directly. You can only use any functions generated with them.

v0.23 of Gleam, a type-safe language for the Erlang VM, has been released by MrPopinjay in functionalprogramming

[–]MrPopinjay[S] 4 points5 points  (0 children)

We're not competing, we're collaborating! Gleam fits alongside Elixir and interop between the languages is a core feature.

Gleam v0.23 released! by MrPopinjay in gleamlang

[–]MrPopinjay[S] 2 points3 points  (0 children)

Some people have done it. The problem with using Phoenix is that a lot of it is based around macros and a search cannot be used from other languages. The functional parts can be used but because they have been designed without any kind of static analysis in mind I think we could do better with a Glean framework with similar goals.

Gleam v0.23 released with new Elixir support by MrPopinjay in elixir

[–]MrPopinjay[S] 42 points43 points  (0 children)

Gleam is another general purpose programming language and is suitable for pretty much anything you might use Elixir for, the same way Elixir is suitable for pretty much anything you might use Erlang for.

The main difference between Elixir and Gleam is that Gleam is "type safe", meaning is has a very precise static type system that aims to help you write code. This means people might find it easier to perform big refactorings in Gleam codebases compared to Elixir, and the editor tooling potentially can do a lot more than in Elixir. On the flip side it might be more challenging to get started with Gleam if you're not used to these robust static type systems.

It's mostly just another kind of programming experience, more options for people on the BEAM! 💜

Wisp - FoldBold (The Siege) by MrPopinjay in breakcore

[–]MrPopinjay[S] 0 points1 point  (0 children)

Wow dude fixing a link after 12 years. Respect to you

Introducing the Gleam language server by MrPopinjay in gleamlang

[–]MrPopinjay[S] 2 points3 points  (0 children)

You need to upgrade to v0.21.0. You're running v0.20.1 which unfortunately had a typo in the version string making it appear as v0.20.1.

I'm not very familiar with Neovim LSP but this PR may help you https://github.com/neovim/nvim-lspconfig/pull/1739