v3.6.2 -------- This release adds support for nested quasi-quotation forms, which now respect depth level. This was done by replacing the quasi-quotation special form with a macro based on the one from chibi scheme. A nice side-benefit is that by removing the special forms, quasi-quotation now works in the compiler. Also added support for SRFI 2, `and-let*`. From the SRFI document: > Like an ordinary AND, an AND-LET\* special form evaluates its arguments - expressions - one after another in order, until the first one that yields #f. Unlike AND, however, a non-#f result of one expression can be bound to a fresh variable and used in the subsequent expressions. AND-LET\* is a cross-breed between LET\* and AND. And added support for environment specifiers, including the following functions: - `(interaction-environment)` - `(current-environment)` - `(make-environment)` - `(null-environment version)` - `(load filename environment-specifier)` - `(eval expression environment-specifier)` This release also includes the following bug fixes: - Fixed a bug where nested explicit renaming macros may not always expand properly. - Unfortunately, the storage model changes introduced in 3.6 cause problems with hash table literals defined using the `#hash()` syntax. For now, hash table literals have been removed to prevent further problems. This feature may be added back in the future. - Fixed the code for `require-extension` to allow passing multiple SRFI numbers in the same call. For example: `(require-extension (srfi 1 2))`. - Improved compiler support by diverting renamed variables back into the enclosing environment. Such variables would previously throw a runtime error when accessed by the compiled program. - Improved compiler support by loading macros defined using `define-syntax` so they are available at runtime. v3.6.1 -------- Added support for GHC 7.6. v3.6 -------- Enhanced the variable storage model to correctly store references to objects. For example, consider the following: (define x (list 'a 'b 'c)) (define y x) (set-cdr! x 4) After executing this code, previous versions of husk assigned `(a b c)` to `y`. With this release, husk now evaluates `y` to the expected value of `(a . 4)`. The more general problem is that certain data types denote a memory location which may be modified by mutator functions such as `set-cdr!`. This is discussed specifically in section 3.4 Storage Model: > > Variables and objects such as pairs, vectors, and strings implicitly denote locations or sequences of locations. A string, for example, denotes as many locations as there are characters in the string. (These locations need not correspond to a full machine word.) A new value may be stored into one of these locations using the string-set! procedure, but the string continues to denote the same locations as before. > Internally husk uses Haskell data types, so the husk model differs slightly from the one in R5RS - references are used instead of individual memory locations. This has implications for the `set-car!` and `set-cdr!` special forms, where circular lists and similar low-level optimizations are not possible as Haskell lists are used instead of raw pointers. However, these issues aside, the enhanced storage model is a big step forward to bringing husk's variable support closer in line to that of other Schemes. v3.5.7 -------- The major change in this release is support for explicit renaming macros. This low-level macro system provides the ability to break macro hygiene, if necessary, and offers a macro system that is similar to `defmacro`. In addition, all of the character functions from R5RS have been implemented. v3.5.6 -------- - Enhanced the compiler to accept `load-ffi` as a special form, so a compiled version of a program does not have to wait for a module to be dynamically loaded. Instead, the module is included at compile time. This offers a nice speed improvement:
$ time huski ffi-cputime.scm
Seconds of CPU time spent: 2.756171
$ time ./ffi-cputime
Seconds of CPU time spent: 2.4001e-2
- Allow a hash table to be defined directly using `#hash(alist)` - for example, `#hash()` for an empty table or `#hash((a 1) (b . 2))` for a table with two elements. This is not part of R5RS but seems less clumsy than the standard way, and a similar language feature is provided by Racket.
- Added support for `hash-table-set!` and `hash-table-delete!` to the compiler.
- Fixed a bug where `integer?` would always return false for negative rational numbers. For example, `(integer? -2/2)` should evaluate to `#t`.
v3.5.5
--------
- Added support for SRFI-1 (List Library), which can be loaded using `(require-extension (srfi 1))`. Note that linear update functions (such as `map!`, `take!`, etc) and circular lists are not supported at this time.
- Added a new LispVal type called `Opaque` for Haskell integration, courtesy of Josh Triplett. The Opaque type allows a native Haskell function to package an arbitrary Haskell type for use by other native code called by husk. See `examples/ffi/Opaque.hs` for an example of how to use this feature.
- Implemented `file-exists?`, `delete-file`, `char-ready?`, `rationalize`, `gcd`, and `lcm`.
- Enhanced the parser to read numbers in scientific notation such as `1e3` and `4.2e1`.
- Modified `numerator` and `denominator` to add support for integers and floating point numbers.
- Fixed a bug in `set-cdr!` where an unsimplified list may be output. For example, `(3 . (2 . (1 . ())))` instead of `(3 2 1)`.
- Allow `apply` to receive multiple arguments, as long as the last one is a list.
v3.5.4
--------
- Enhanced `huski` and `huskc` to print errors to console when a runtime exception occurs,
and to not print any results to console unless the user calls an I/O function
such as `write` or `display`.
- Added a special form `expand` that can be used to see the result of a macro
expansion, for debugging purposes. For example: `(expand (let ((x 1)) x))`.
- Allow a list to be enclosed by matched brackets as well as parentheses. For example: `(+ 1 2 [+ 3 4])`.
- Internal change - cleaned up code by using Language pragmas instead of explicitly using extensions in the cabal and make files.
v3.5.3.2
--------
- Modified huski to escape baskslashes in the path to the standard library, to guarantee stdlib is loaded when husk is installed on a Windows machine.
v3.5.3.1
--------
- Removed an unnecessary dependency on `/dev/null` to allow `huski` to interpret files when run on Windows.
- Prevent divide-by-zero errors when dividing by a single number, or processing a rational number with zero as the denominator.
v3.5.3
------
This release adds full support for GHC 7.2.2 / 7.4.1 as well as a number of small enhancements.
- Fixed the FFI to work in both GHC 7.2.2 and GHC 7.4.1.
- Implemented SRFI 23, which adds error reporting via the `(error)` function.
- Added support for `let-syntax`, `letrec-syntax`, `set-car!`, `set-cdr!`, `vector-set!`, and `lambda` (pair syntax) to the huskc compiler.
- Added the `--dynamic` option to the compiler to use dynamic Haskell libraries.
- Added the `--extra` option to the compiler to allow passing of arbitrary arguments directly to ghc.
- Fixed huski to allow any redefinition of `let-syntax` and `letrec-syntax`.
v3.5.2.x
------
This is a series of quick bug-fix releases that allows husk to build under GHC 7.4.1.
v3.5.2
------
- Added an experimental compiler, huskc. For more information see [Issue #62](https://github.com/justinethier/husk-scheme/issues/62).
- Streamlined the cabal file so that each source file is only compiled a single time.
v3.5.1
------
- Improved support for comparing instances of functions using `eq?`, `eqv?`, etc.
- Reduced variable access time by using a Map to store variables within an environment.
- Various internal changes such as renaming the tests directory and integrating R5RS pitfalls with the unit tests.
v3.4.4
------
This release continues the trend of quick point releases for the 3.4.x series. The key change is support for GHC 7.2:
- husk now compiles in GHC 7.2. This ended up being a simple change - I had mis-interpreted the value of a pre-processor directive. Sorry about that!
- Replaced the definition of `letrec` with the macro from R5RS.
- Allow a continuation to call into another continuation via call/cc - see R5RS pitfall 1.2
v3.4.3
------
- Fixed `let-syntax` and `letrec-syntax` to prevent conflicts between identifiers of the same name in the outer scope and within the macro body.
- Per R5RS, `(if