* module/mes/psyntax-1.mes (syntax-rules): New syntax transformer,
based on syntax-case.
(define-syntax-rule): New macro.
(let-syntax): New macro, for syntax-case.
* tests/let-syntax.test: Switch to syntax-case.
* tests/psyntax.test: Add syntax-rules and syntax-rule test.
* mes.c (sc_expand_env): New function.
(builtin_eval): Use it.
* module/mes/psyntax-0.mes: New file.
* module/mes/psyntax-1.mes: New file.
* tests/psyntax.test: New file.
* GNUmakefile (TESTS): Add it.
* module/mes/psyntax.mes: New file.
* module/mes/psyntax.ss: New file.
commit 230c435383087a1e6ad60d9c98d3ec75dd2c3e49
Author: Mikael Djurfeldt <djurfeldt@nada.kth.se>
Date: Tue Aug 19 01:28:50 1997 +0000
* syncase.scm: New file: Guile-adaption for syntax-case macros.
psyntax.pp, psyntax.ss: Syntax-case macros, portable version 2 by
R. Kent Dybvig, Oscar Waddell, Bob Hieb and Carl Bruggeman
* mes.c (make_cell): New primitive alongside make_vector for allocation.
(cons, make_char, make_macro, make_number, make_ref,
internal_make_symbol, make_vector): Use it.
* mes.c (scm_t): Add string field.
(make_string, internal_lookup_symbol, internal_make_symbol,
make_symbol, lookup, readword): Take scm*. Update callers.
(display_helper): Support string field.
(append_char): New function.
(readstring): Use it. Produce scm*.
(cstring_to_list): New function.
(add_environment, internal_make_symbol): Use it.
(list_of_char_equal_p): New function.
(internal_lookup_symbol): Use it.
* lib.c (list_ref): New function.
* string.c (string_ref): Use it.
(string, string_append, string_length, substring, number_to_string,
string_to_symbol, symbol_to_string): Update to list-of-characters
implementation.
* mes.c (apply_env, main): Call begin rather than eval with cons'ed
symbol begin.
* module/mes/mes-0.mes (apply-env): Likewise.
* quasiquote.c (add_unquoters): cons global unquoters rather than
creating it fresh.
* module/mes/mes-0.mes (add-unquoters): Likewise.
* mes.c (char_p, macro_p, number_p, pair_p, string_p, symbol_p,
vector_p, builtin_p, boolean_p): Move to type.c
* type.c: New file.
* GNUmakefile (mes.o): Depend on type snarf output.
* module/mes/loop-0.mes (cond, map, let, or, and not, evlis-env,
apply-env, eval-expand, uquote, add-unquoters, eval,
expand-macro-env, eval-begin-env, eval-if-env, sexp:define,
env:define, env:macro): Move to mes-0.mes.
* module/mes/mes-0.mes: New file.
* module/mes/type-0.mes: New file.
* scripts/include.mes: If BOOT, also include mes-0.mes. If TYPE0,
also include type-0.mes.
* mes.c: Move specific renames and n-args to alist annotation.
* build-aux/mes-snarf.scm: New file.
* GNUmakefile (mes.environment.h): Use it.
(mes.h): Remove.
(clean): Update.
(mes.o): New dependency rule.
* .gitignore: Update.
* mes.c (make_vector): Change to scm interface.
(temp_number): New global.
(list_to_vector): Use it.
* module/mes/scm.mes (c:make-vector): New function.
* tests/scm.test: Remove vector tests.
* tests/vector.test: New file.
* GNUmakefile (TESTS): Add it.