Releases: RedPRL/asai
0.3.1
This is a minor release with several improvements, especially the debug mode to actively detect invalid ranges. OCaml 5.2.0 introduced backward-incompatible changes in ocaml/ocaml#12477 and thus we had to bump up the minimum OCaml version.
Bug Fixes
- correct and enhance the debug mode (#142) (db89139)
- Diagnostic: use
Format.pp_infinity
instring_of_text
for OCaml 5.2 (#149) (b835fac) - dim the carets (#145) (08c7dc2)
Features
0.3.0
This is a major release with two notable changes:
- New special
EOF
ranges were introduced to highlight the end of a file. The terminal renderer will show “‹EOF›” and highlight it if a specialEOF
range is used. - The terminal renderer was rewritten (again). Its visual appearance is almost identical to the previous one, except that the “faint” style replaces the gray coloring. Internally, it no longer uses
notty
(thus reducing the dependencies to a minimum), and it now automatically detects the environment variableNO_COLOR
, following the specification at https://no-color.org/.
BREAKING CHANGES
- Range: because of the new special
EOF
ranges,split
is deprecated and will be removed soon; useview
instead
Bug Fixes
- Reporter: backtrace frames no longer inherit locations (#128) (bbd7d0b)
- Tty: drop
notty
and use the "faint" style (#135) (1988a5a) - upgrade the dependency
algaeff
to 2.0.0 (#132) (6e8b9a2)
Features
0.2.0
This is a major release with many backward incompatible changes.
The most significant change is the introduction of StructuredReporter. The library can thus be used in two different modes:
- Use Reporter (as the old Logger): its API is biased towards free-form explanations.
- Use StructuredReporter: its API is biased towards fully structured messages.
Both modes share the same type of diagnostics, and thus, an application using structured messages can adopt a library using free-form explanations and vice versa. Great care has been taken to make sure the two modes can work together. The current tutorial focuses on Reporter and free-form explanations because we think that mode is slightly easier to set up.
The second most significant change is that the TTY handler got an overhaul. The output is now more concise, informational, and beautiful.
Thanks to @mikeshulman for many valuable suggestions.
BREAKING CHANGES
- Span is renamed to Range
- Logger is renamed to Reporter and Reporter.Code is renamed to Reporter.Message
- Range: the type
position
was changed to allow string (in-memory) sources - Diagnostic: the type
diagnostic
was changed andmessage
was renamed toloctext
- The LSP handler is separated out as a new package (not published yet)