Commit graph

3261 commits

Author SHA1 Message Date
Ekaitz Zarraga
57c5940855 Unparse Array and Object types 2020-05-22 12:10:42 +02:00
Ekaitz Zarraga
35cdd287ea Unparse string 2020-05-22 12:10:42 +02:00
Ekaitz Zarraga
de5a4b6b28 Copyright headers 2020-05-22 12:10:42 +02:00
Alex Shinn
62ef654817 clarifying in README that GNU make is used, movign all extensions to Makefile.detect (issue #642) 2020-05-22 15:06:45 +09:00
Alex Shinn
61f2983fad apply an explicit max vector length check (issue #636) 2020-05-22 14:13:48 +09:00
Alex Shinn
b459e11ecf
Merge pull request #647 from ekaitz-zarraga/float_parse
Correct float parsing when exponent has sign
2020-05-22 10:35:13 +08:00
Alex Shinn
bda192f071 cleanup json unicode escape code 2020-05-22 11:32:19 +09:00
Alex Shinn
278657eea4
Merge pull request #644 from ekaitz-zarraga/master
Support multiple \u sequences and add error checking
2020-05-22 10:11:10 +08:00
Ekaitz Zarraga
1cc24e37d9 Fix formatting 2020-05-22 00:30:24 +02:00
Ekaitz Zarraga
ce1996f1a7 Correct float parsing when exponent has sign 2020-05-21 18:10:54 +02:00
Ekaitz Zarraga
64d04f0638 Add JSON tests 2020-05-20 13:11:12 +02:00
Ekaitz Zarraga
e79d2aefea Support multiple \u sequences and check errors 2020-05-19 20:47:19 +02:00
Alex Shinn
8df9f7ca69
Merge pull request #643 from ekaitz-zarraga/master
Support for \u sequences in JSON
2020-05-19 09:18:00 +08:00
Ekaitz Zarraga
c448e8b441 Support for \u sequences in JSON 2020-05-18 22:39:33 +02:00
Alex Shinn
62efe38c70
Merge pull request #641 from amirouche/fix-emscripten-build
Fix build with emscripten to run chibi in the browser.
2020-05-17 19:17:13 +08:00
Amirouche
d2006daa3c Fix build with emscripten to run chibi in the browser.
emcc (Emscripten gcc/clang-like replacement) 1.39.16 (9ecd579ac647c4484e2d9af2ab0bbc1e1505aa95)

Thanks @pmp-p.
2020-05-17 10:52:46 +02:00
Alex Shinn
6e8b9bf59d adding srfi 165 2020-05-17 00:08:00 +09:00
Alex Shinn
af7189e895
Merge pull request #640 from Donaim/601
Prevent stack overflow in sexp_mark_one (issue #601)
2020-05-16 22:13:27 +08:00
Vitaliy Mysak
5726c2e490 Prevent stack overflow in sexp_mark_one (issue #601)
Replace explicit recursion by heap allocations
in sexp_mark_one code.
This prevents crashes caused by stack overflow.
In particular, fixes issue #601.

As an optimization, allocate a fixed sized stack buffer first,
which should be enough for "normal" uses.
When that stack overflows, switch to heap.

Also, store "ranges" on the stack, instead of the actual sexp's,
using the fact that sexp's of a single parent are continous in memory.

This patch doesn't remove recursion on the context saves
because it didn't seem like they overflow in practice.
But changing that is simple having the stack interface.
2020-05-15 20:11:50 +02:00
Alex Shinn
4be920986f
Merge pull request #639 from Donaim/638
Avoid undefined C macro behavior
2020-05-14 08:11:36 +08:00
Donaim
bd62a076c6 Avoid undefined C macro behavior
MacOS and clang compilers complain about undefined behavior
in C macro.
Rewrite macro to solve that.

Fixes issue #638
2020-05-13 22:23:17 +02:00
Alex Shinn
72e70bef88
Merge pull request #637 from Donaim/fix-c89-compilation
Fix c89 compilation and add test build option for it
2020-05-13 18:18:39 +09:00
Vitaliy Mysak
9c680217d7 tests: add std=c89 as build option
Since chibi already compiles with c89,
it should not be too bad to maintain this compatibility.
2020-05-13 11:12:02 +02:00
Vitaliy Mysak
f449bd157d fix compilation under std=c89
There were few things that prevented successful compilation
using c89 standard. (and other c* standards in case of gcc).
Fix them in this small patch.

Changes in 27/rand.c:
- Use __GNU_SOURCE__ instead of __GNU_LIBRARY__
  or else any of -std=c* options don't work with gcc
- Add a check before using rand_r() as suggested in rand_r(3)
- Move _WIN_32 definitions to "else" branch because it uses the most portable version
2020-05-13 11:12:02 +02:00
Alex Shinn
e7e6530c35
Merge pull request #635 from Donaim/uninstall-misses
make: fix uninstall target
2020-05-12 10:43:21 +09:00
Alex Shinn
89201a4e20 remove bad redefinition of sexp_context_gc_count (issue #632) 2020-05-12 10:39:27 +09:00
Donaim
ebfe494147 make: fix uninstall target
uninstall target failed to remove
- share/srfi libraries
- man pages
- include headers

This patch repairs the makefile so that all chibi files
get removed correctly.

In case of man pages, they were actually installed
to a wrong place - "man1/man1" instead of "man1".
This was introduced by 2137fcd3f0
so current commit reverts it.
2020-05-11 23:19:48 +02:00
Alex Shinn
610b6964ce fix log table for integer-length (issue #634) 2020-05-11 21:38:40 +09:00
Alex Shinn
426579eef2 Merge branch 'master' of github.com:ashinn/chibi-scheme 2020-05-11 10:45:24 +09:00
Alex Shinn
83e82f55a7 tweaks for fixed-size heaps, fix issue #632 2020-05-11 10:43:36 +09:00
Alex Shinn
90b0336048 report diff on gc times 2020-05-11 10:28:00 +09:00
Alex Shinn
fe7ae7ca48
Merge pull request #633 from ar-nelson/srfi-133-vector-every-fix
Fix SRFI 133 vector-every crash on empty vector
2020-05-10 01:12:44 +09:00
Adam R. Nelson
18a5776587 Fix SRFI 133 vector-every crash on empty vector 2020-05-09 11:46:10 -04:00
Alex Shinn
abe8ca3b95 obi-wan error 2020-05-07 21:48:51 +09:00
Alex Shinn
e3db106f96 instrumenting alloc times and sizes 2020-05-06 23:39:01 +09:00
Alex Shinn
a4dcd04127
Merge pull request #631 from mnieper/srfi-158
Implement SRFI 158.
2020-05-06 07:48:23 +09:00
Marc Nieper-Wißkirchen
15b3449b85 Implement SRFI 158. 2020-05-05 22:28:10 +02:00
Alex Shinn
9100909ae1 better defaults and debugging for fixed size chunks 2020-05-05 00:41:20 +09:00
Alex Shinn
696bf30f5e check for circular lists in apply (issue #629) 2020-05-03 17:19:24 +09:00
Alex Shinn
156ddf793d better benchmark timing 2020-05-03 17:05:53 +09:00
Alex Shinn
c43285e5f2
Merge pull request #630 from mnieper/srfi-162
Implement SRFI 162.
2020-05-03 08:05:57 +09:00
Marc Nieper-Wißkirchen
d4527d23dc Implement SRFI 162. 2020-05-02 21:05:19 +02:00
Alex Shinn
69aed93502
Merge pull request #627 from lassik/usage
Write usage to stderr when bad options given
2020-04-23 21:31:49 +09:00
Lassi Kortela
bb0a0054c8 Write usage to stderr when bad options given 2020-04-23 13:59:27 +03:00
Alex Shinn
957ffe6a42 return successfully on --help (issue #626) 2020-04-23 19:27:52 +09:00
Alex Shinn
361dc48c62 don't verify duplicate formal parameters for more than 100 params 2020-04-19 19:20:01 +09:00
Alex Shinn
f74c34b99b make-promise is idempotent (issue #625) 2020-04-10 17:17:29 +09:00
Alex Shinn
0a83939866 fix corner case with multi-line comments in non-native read (issue #623) 2020-03-30 01:14:27 +09:00
Alex Shinn
72ea1258e6
Merge pull request #622 from katterjohn/address-info-canonname
(chibi net): add address-info-canonname
2020-03-25 16:16:28 +08:00
Alex Shinn
1795014dae throw an error on get-output-string on non-string-ports (issue #621) 2020-03-25 17:15:06 +09:00