Skip to content

Latest commit

 

History

History
80 lines (55 loc) · 1.94 KB

CHANGELOG.md

File metadata and controls

80 lines (55 loc) · 1.94 KB

Changelog

v1.3.0 - Unreleased

Build tool

Compiler

  • The compiler now emits a warning for redundant function captures in a pipeline:

    warning: Redundant function capture
      ┌─ /src/warning/wrn.gleam:5:17
      │
    5 │     1 |> wibble(_, 2) |> wibble(2)
      │                 ^ You can safely remove this
    
    This function capture is redundant since the value is already piped as the
    first argument of this call.
    
    See: https://tour.gleam.run/functions/pipelines/
    

    (Giacomo Cavalieri)

  • Functions etc named maybe are now escaped in generated Erlang as it is now a reserved word in Erlang/OTP 27. (Jake Barszcz)

Formatter

Language Server

  • The language server will now suggest the "Remove redundant tuple" action even if the case expression contains some catch all patterns:

    case #(a, b) {
      #(1, 2) -> todo
      _ -> todo
    }
    

    Becomes:

    case a, b {
      1, 2 -> todo
      _, _ -> todo
    }
    

    (Giacomo Cavalieri)

Bug Fixes

  • Fixed a bug where the compiler would output a confusing error message when trying to use the spread syntax to append to a list. (Giacomo Cavalieri)

  • Fixed a bug where the formatter would strip empty lines out of the body of an anonymous function passed as an argument. (Giacomo Cavalieri)

v1.2.1 - 2024-05-30

Bug Fixes

  • Fixed a bug where the compiler could fail to detect modules that would clash with Erlang modules. (Louis Pilfold)

  • Fixed a bug where dependency version resolution could crash for certain release candidate versions. (Marshall Bowers)

  • Fixed a bug where trailing comments would be moved out of a bit array. (Giacomo Cavalieri)