Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases now! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon

Elm 0.19.1 releases with improved syntax error messages in the Elm compiler

Save for later
  • 2 min read
  • 22 Oct 2019

article-image

Yesterday Elm 0.19.1 was released with a new improvements to the compiler that now display syntactical errors in a new fashion that pointing users to their mistakes as well as suggesting them additional resources.  The goal of 0.19.1 is to clean up the rough edges such that we have a really solid foundation for newcomers, professionals, scientists.

Evan Czaplicki, the creator of these improved error messages explains in a blog post, “the new error messages points to the spot where it got stuck, but more importantly, it tries to help by (1) giving examples and (2) linking to a page that explains how imports work. It tries to help you learn!”

For example, if you miss out on including a curly braces in your JavaScript code, the error message shows up at the very end of the file. Now with the improved Elm compiler, the error message will point out the error where it occurred while also suggesting a viable fix.

elm-0-19-1-releases-improved-syntax-error-messages-elm-compiler-img-0

Source: Elm’s blog


Czaplicki hopes that this project can eliminate the survivorship bias present in the programming ecosystem, which he believes is also one of the reasons why it took so long for Elm to prioritize this project. “I hope this work on syntax error messages will help make Elm more friendly and accessible, and I hope it will help make space for other language designers to prioritize this kind of project!”, he adds.

Other improvements in Elm 0.19.1

  • Faster compilation, especially for incremental compiles
  • Unlock access to the largest independent learning library in Tech for FREE!
    Get unlimited access to 7500+ expert-authored eBooks and video courses covering every tech area you can think of.
    Renews at $19.99/month. Cancel anytime
  • Uses filelocks so that cached files are not corrupted when plugins run elm make multiple times on the same project at the same time.
  • More intuitive multiline declarations in REPL
  • Various bug fixes (e.g. --debug, x /= 0, type Height = Height Float in --optimize)


Developers on Twitter appreciated Elm’s focus on errors.

https://twitter.com/vronnie911/status/1186377031015157762

https://twitter.com/domenkozar/status/1163795173022806016

Read more about improved error messages in Elm 0.19.1 on this blog post.

What to expect from D programming language in the near future

OpenBSD 6.6 comes with GCC disabled in base for ARMv7 and i386, SMP improvements and more.

Swift shares diagnostic architecture improvements that will be part of the Swift 5.2 release.