Skip to content

Commit

Permalink
CHANGELOG!
Browse files Browse the repository at this point in the history
  • Loading branch information
giacomocavalieri authored and lpil committed Apr 29, 2024
1 parent 73691d1 commit 8810a03
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,29 @@

([Pi-Cla](https://github.com/Pi-Cla/))

- The compiler will now raise a warning when you try to use `todo` or `panic` as
if they were functions: this could previously lead to a confusing behaviour
since one might expect the arguments to be printed in the error message.
The error message now suggests the correct way to add an error message to
`todo` and `panic`.

```
warning: Todo used as a function
┌─ /src/warning/wrn.gleam:2:16
2 │ todo(1)
│ ^
`todo` is not a function and will crash before it can do anything with
this argument.
Hint: if you want to display an error message you should write
`todo as "my error message"`
See: https://tour.gleam.run/advanced-features/todo/
```

([Giacomo Cavalieri](https://github.com/giacomocavalieri))

### Formatter

- Redundant alias names for imported modules are now removed.
Expand Down

0 comments on commit 8810a03

Please sign in to comment.