Fork me on GitHub

Released Version 3.10

This release includes important fixes / enhancements to the compiler, and is a major step in moving huskc from an experimental project to a tool that can be used for real-world applications.

Most of the changes were inspired by a Haskell port of The 90 Minute Scheme to C compiler by Marc Feeley.

Anyway, the changes for the 3.10 release are as follows:

  • Significantly reduced the amount of compiled Haskell code generated by huskc, leading to a 40% reduction in the code generated by the compiler test suite. Note any actual percentages will depend upon the scheme code being compiled.
  • Added load as a compiler special form, to allow code to be loaded from other files and compiled alongside the main program.
  • Added optimizations to evaluate primitive expressions at compile time, and to generate more efficient code for functions that are only passed literal arguments.
  • Enhanced the compiler to detect undefined variables and report an error at compile time, instead of generating code that will throw a runtime error.
  • Fixed an issue where the compiler would not cache macro expansions in its local memory when compiling function definitions. This bug caused problems for explicit renaming macros, as it was possible for the evaluator to evaluate a special form thinking that it was a function, resulting in an “unbound variable” error.
  • Modified the test suite to work with both the interpreter and compiler. Note that some test cases are not executed by the compiler because they are not supported (see below).
  • SRFI 1 is not supported by the compiler at this time.
  • Finally, the huskc version page was updated to print the full husk scheme banner.

<< More news and updates