Version 0.44.0 released
Published on:
This minor release brings a lot of refactoring and a few breaking changes related to sigils and introduces a new concept of dot notation for symbols.
In previous releases, it was possible to use the invoke symbol (and the * sigil) to access members of a dictionary or modules, e.g. *crypto/encode to access the crypto.encode symbol of the crypto Module module. This was fine, but a little bit verbose… plus this didn’t work for setting values, for example.
As of this release, you can no longer use . in symbols, because that will be used as a namespace separator, so you’ll be able to do things like this:
{} :example
(dup *) :example.square
(dup dup * *) :example.cube
2 example.square example.cube puts! # Prints 64
Tip
You can run min run min-upgrade <folder> to automatically upgrade all the .min files in <folder> and all its subfolders.
BREAKING CHANGES
- User-defined symbols can no longer contain dots (.).
- The symbol invoke and the * sigil have been removed in favor of symbol dot notation.
- The . and .. symbols have been renamed to pwd and parent-dir respectively.
- The ! symbol has been removed; use system instead.
- The ! sigil has been removed; use system instead.
- The & symbol has been removed; use run instead.
- The & sigil has been removed; use run instead.
- The / sigil has been removed; use dget or symbol dot notation instead.
- The % sigil has been removed; use dset or symbol dot notation instead.
- The > sigil has been removed; use save-symbol innstead.
- The < sigil has been removed; use load-symbol innstead.
- Moved get-env, put-env, $ symbol and $ sigil from sys to global module.
New Features
- It is now possible to access dictionary (and module) keys (even nested) via dot notation. This replaces the invoke symbol.
- Added shell auto-completion for symbols using dot notation
- Added a new color symbol to the io module to enable/disable terminal color output.
- Added a new from-html symbol to the xml module to parse HTML documents and fragments.
- Added a new xentity2utf8 symbol to the xml module to convert an XML entity to its corresponding UTF-8 string.
- Added a new xescape symbol to the xml module to convert special XML characters into the corresponding XML entities.
Fixes and Improvements
- Fixed tokenize symbol (wasn’t processing commands correctly)