Projects / 4tH compiler

4tH compiler

4tH is a Forth compiler with a little difference. Instead of the standard Forth engine it features a conventional compiler. 4tH is a very small compiler that can create bytecode, C-embeddable bytecode, standalone executables, but also works fine as a scripting language. It supports about 95% of the ANS Forth CORE wordset and features conditional compilation, pipes, files, assertions, forward declarations, enumerations, structures, suspended execution, recursion, include files, etc. It comes with an RPN calculator, line editor, preprocessor, compiler, decompiler, C-source generator, a virtual machine, and a multitasking environment.

Tags Software Development Libraries Code Generators Compilers
Licenses LGPL
Operating Systems Windows MS-DOS POSIX Linux Windows Windows Windows Mac OS X BSD
Implementation Forth C

Tweet this project Short link

Rss Recent releases

Changes: A preprocessor was added. The multitasking environment was rewritten. Several ANS floating point bugs were fixed. Another floating point environment, called Zen float, was added. The Linux version now supports shared libraries. More complex patches are supported. Various other additions and fixes were made to the libraries and examples.

  • Rrelease-mid
  •  03 May 2009 14:25
  • Rrelease-after

Changes: Several bugs in the floating point library were fixed. The circular ring buffer library was rewritten. Many FSL and forth200x words were added to the library. The return value of "OPEN" was standardized. "AS" was removed. "ERROR?" and "BUFFER:" were added. The editor can now export text files. A classic "Startrek" program was added to the examples. New sections were added to the Development Guide.

Changes: A floating point emulation library was added, providing most words of the FLOATING and FLOATING EXT wordsets. A few bugs were fixed in the "mixed" library.

Changes: A default 4tH directory can be defined by setting an environment variable. Support for creating custom 4tH implementations was added. The multitasking environment is scriptable now. The library files concerning ANS Core Extensions, table searching, and interpretation have been rewritten or replaced.

  • Rrelease-mid
  •  23 Dec 2007 11:03
  • Rrelease-after

Changes: The words C and OFFSET have been added. The multitasking environment has been fully integrated in the source tree.

6bf89143b7cb7c338bead586b3acc939_thumb

Project Spotlight

Kusaba X

A quick, easy way to set up and manage your own image board.

B6e3249d4f5490371b30f6f1b4aaefb9_thumb

Project Spotlight

PeaZip

A file and archive manager that supports many compression and archive formats.