Official chibi-scheme repository
Find a file
Jim Rees 88e8d89460 Fixed integer-log-base to use exact arithmetic so rounding doesn't cause
a wrong result to things like (numeric (- (* 36 36 36) 1) 36).

Fixed a bug in numeric that caused comma-sep and dec-sep to get
initialized wrongly.

Fixed maybe-trim-zeros to leave behind at least a ".0" on
inexact numbers that otherwise would have been output without
the decimal point.  This is for consistency with number->string
which is used when the radix is 10.

In gen-general, fixed a bug in the digit-generating loop for the
whole part of the number.  Previously, an integer that should
have looked like 5003 would be emitted as 5300.

Switched the order of application of maybe-round and
maybe-trim-zeros so that a number that should round to
.0000000000000001 doesn't get emitted as 0.1.

In gen-positive-real, fixed the ratio case to not call
number->string with a radix that might not be in {2,8,10,16}.

Also in gen-positive-real, fixed the call to number->string to
include the radix which was missing previously.

Fixed wrap-sign to correctly handle the case of -0.0.

In numeric/si, always emit the supplied separator even if the
number is too small for an SI-suffix to be emitted.  The
examples in the SRFI document depend on this.
2018-03-23 12:22:03 -04:00
benchmarks adding count to gc timer 2015-06-27 20:43:43 +09:00
build-lib/chibi/char-set Noting some simple char-set utilities are public domain. 2015-04-09 01:43:17 +09:00
contrib cmake: Add CMakeLists.txt 2017-11-18 16:28:31 +09:00
data Adding a gitignore for the temp data dir. 2015-04-09 01:30:06 +09:00
doc Documenting sexp_register_c_type and sexp_make_cpointer. 2018-02-18 09:19:36 +09:00
examples Forgot to install regexp (patch from Lorenzo) 2015-01-26 08:06:59 +09:00
include/chibi Introduced a second version of sexp_double_to_ratio, named 2018-03-22 22:19:39 -04:00
js Integrate emscripten build process in Makefile 2015-06-23 19:57:07 +02:00
lib Fixed integer-log-base to use exact arithmetic so rounding doesn't cause 2018-03-23 12:22:03 -04:00
opt making string-cursors a disjoint type 2016-03-29 22:25:09 +09:00
tests Add regression tests for remainder with infinity. 2018-03-15 21:48:19 -05:00
tools chibi-genstatic: Add --no-inline option 2017-11-08 01:12:54 +09:00
.gitignore Update .gitignore 2017-12-31 07:32:23 +09:00
.hgignore Emscripten support by default. Patch from Marc Nieper-Wi?kirchen. 2015-02-22 16:10:30 +09:00
.travis.yml wrong filename 2016-06-24 22:51:36 +09:00
appveyor.yml AppVeyor: Add CMake x64 MinGW configuration to check 2017-12-31 07:32:22 +09:00
AUTHORS adding (srfi 135) 2018-01-16 01:14:40 +09:00
bignum.c Changed sexp_double_to_bignum to extract "digits" in base-16 rather 2018-03-23 10:50:15 -04:00
chibi-gdb Previous checkin incomplete - fixed omissions 2016-02-17 12:15:36 -05:00
chibi-run Bit better error reporting 2016-02-16 12:10:28 -05:00
chibi-save Made static definitions for srfi/95 and srfi/27 so work with images. Put makefile back to -O3 so optimized binaries made by default 2016-02-20 09:16:58 -05:00
chibi-scheme.pc.in Forgot to install regexp (patch from Lorenzo) 2015-01-26 08:06:59 +09:00
CMakeLists.txt skip chibi log tests in windows 2018-01-13 10:57:44 +09:00
configure adding informational configure script 2016-06-24 22:55:08 +09:00
COPYING adding (srfi 101) 2018-01-15 23:51:16 +09:00
eval.c Introduced a second version of sexp_double_to_ratio, named 2018-03-22 22:19:39 -04:00
fedora.spec Forgot to install regexp (patch from Lorenzo) 2015-01-26 08:06:59 +09:00
gc.c adding better debugging for zero-sized object warning 2018-02-16 17:01:21 +09:00
gc_heap.c Win32: Fix win32 port 2017-11-11 04:31:06 +09:00
main.c advanced repl should use (scheme small) by default 2018-01-16 21:23:21 +09:00
Makefile Add "test-division" Makefile target. 2018-03-15 21:43:21 -05:00
Makefile.detect Win32: Fix win32 port 2017-11-11 04:31:06 +09:00
Makefile.libs Modify makefiles to make LDCONFIG optional, support systems with no symlinks. 2016-05-18 14:11:39 -07:00
mkfile Forgot to install regexp (patch from Lorenzo) 2015-01-26 08:06:59 +09:00
opcodes.c making string-cursors a disjoint type 2016-03-29 22:25:09 +09:00
plan9.c Updating copyright years. 2015-04-09 01:28:02 +09:00
README-win32.md README-win32.md: Character-case problem was fixed 2017-12-14 18:03:27 +09:00
README.libs Forgot to install regexp (patch from Lorenzo) 2015-01-26 08:06:59 +09:00
README.md doc: Update document for Win32 support 2017-12-13 23:42:18 +09:00
RELEASE bumping version 2017-10-06 23:56:31 +09:00
sexp.c Win32: Include <io.h> on sexp.c 2017-12-13 17:20:53 +09:00
simplify.c Updating copyright years. 2015-04-09 01:28:02 +09:00
TODO marking some todos done 2017-08-30 23:14:50 +09:00
VERSION bumping version 2017-10-06 23:56:31 +09:00
vm.c fixing peek-char on non-ascii chars 2017-06-26 22:23:38 +09:00

Chibi-Scheme

Minimal Scheme Implementation for use as an Extension Language

http://synthcode.com/wiki/chibi-scheme

Chibi-Scheme is a very small library intended for use as an extension and scripting language in C programs. In addition to support for lightweight VM-based threads, each VM itself runs in an isolated heap allowing multiple VMs to run simultaneously in different OS threads.

There are no external dependencies so is relatively easy to drop into any project.

The default repl language contains all bindings from R7RS small, available explicitly as the (scheme small) library. The language is built in layers, however - see the manual for instructions on compiling with fewer features or requesting a smaller language on startup.

Chibi-Scheme is known to work on 32 and 64-bit Linux, FreeBSD and OS X, Plan 9, Windows (using Cygwin), iOS, Android, ARM and Emscripten. Basic support for native Windows desktop also exists. See README-win32.md for details and build instructions.

To build on most platforms just run make && make test. This will provide a shared library libchibi-scheme, as well as a sample chibi-scheme command-line repl. You can then run

sudo make install

to install the binaries and libraries. You can optionally specify a PREFIX for the installation directory:

make PREFIX=/path/to/install/
sudo make PREFIX=/path/to/install/ install

By default files are installed in /usr/local.

If you want to try out chibi-scheme without installing, be sure to set LD_LIBRARY_PATH so it can find the shared libraries.

For more detailed documentation, run make doc and see the generated doc/chibi.html.