Skip to content

Commit

Permalink
Merge pull request #109 from NLnetLabs/changelog-update
Browse files Browse the repository at this point in the history
Update changelog for 0.4.0
  • Loading branch information
density215 authored Jan 29, 2025
2 parents f3d66e2 + aad228a commit 2e49666
Showing 1 changed file with 40 additions and 2 deletions.
42 changes: 40 additions & 2 deletions Changelog.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,53 @@
# Changelog

## Unreleased new version
## 0.4.0

Release yyyy-mm-dd.
Release 2025-01-29.

### Breaking changes

- Filter maps no longer have a `define` and an `apply` block. `let` bindings
should be used instead. For example:

```roto
# Roto 0.3
filter-map foo() {
define {
x = 4;
}
apply {
accept x;
}
}
# Roto 0.4
filter-map foo() {
let x = 4;
accept x;
}
```

### New

- Variables can now be created in more places with `let` bindings. `let`
bindings replace the `define`/`apply` mechanism and are much more general
because they can be used in any block. For example, inside functions or
`if`-`else` blocks. The binding is scoped until the end of the block it is
defined in. It is not allowed to declare multiple variables with the same
name within a single block.
- The `String` type was added to represent pieces of text. String literals
are enclosed in double quotes (`"`).
- It is now possible to declare constants in the runtime for a Roto script.
- Similarly, it is now possible to add "context" to Roto scripts. The variables
in the context behave like constants, but they can differ between different
calls to a script. In other words, constants are defined when the script is
_compiled_, context is defined when the script is _run_.

### Bug fixes

- 64-bit numbers (i.e. `i64` and `u64`) were not type checked and compiled
properly. They are now fixed.

## 0.3.0

Released 2024-11-21.
Expand Down

0 comments on commit 2e49666

Please sign in to comment.