Commit graph

6 commits

Author SHA1 Message Date
Alex Shinn
3ee50bd0d7 length now requires a proper list.
It still accepts cyclic lists and returns #f, like SRFI-1 length+.
It's convenient to be able to accept improper lists (e.g. for
parameter lists), so the old behavior is available as length*.
Fixes issue #97.
2012-07-21 19:22:56 +09:00
Alex Shinn
57b2bc281d apply opcode is now tail-recursive - calling it in a non-tail position is an error 2012-07-18 21:34:53 +09:00
Alex Shinn
5013c0fdcb moving pair-source and pair-source-set! into the core 2012-06-24 14:36:45 -07:00
Alex Shinn
a18deb68cc Optional code refactoring.
Chibi uses a lot of #if conditioned code so that configuration
management can be done entirely with the C preprocessor.

Originally this also involved conditional includes of .c files
from other source files.  The alterative, which this change
switches to, is to compile and link all files, and for uneeded
files conditionally eliminate their entire bodies so they compile
to empty object files.

Pros for conditionally including all code into one large file:

  * Don't need to declare most functions (keeps .h files small).
  * Can keep most functions static/inlined (keeps objects small).
  * Don't need to even distribute uneeded files with the default
    Makefile (e.g. can prune opt/* from dist for minimal builds).

Pros for linking multiple possibly empty files:

  * Extensions and third-party libs probably want the exported
    declarations anyway.
  * Static analysis tools work better (e.g. flymake on what previously
    was an included file).
  * Can build each file in parallel (i.e. make -j for faster builds).
  * Can build and link in just the changed files, instead of
    having to recompile the whole thing.

For Chibi these are all minor points - it will be small
regardless, and will build fast regardless - but the arguments
for splitting seem stronger.  Note the new shared lib is about
1k larger, but that can be trimmed down later.
2012-06-21 23:04:07 -07:00
Alex Shinn
c4bf82842c updates for changes from results of the fifth ballot 2012-05-20 18:44:25 +09:00
Alex Shinn
85a7efc003 automatically making sockets non-blocking on accept 2012-05-14 08:37:45 -04:00