1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-04-30 03:40:34 +02:00
guile/module
Andy Wingo 2053592214 Allow mixed local definitions and expressions
This change to the expander allows mixed local definitions and
expressions.  The expansion turns:

  (let () (a) (define (b) 42) (b) (b))

into:

  (let ()
    (letrec* ((t0 (begin (a) (if #f #f)))
              (b (lambda () 42)))
      (b)))

Which is to say, expressions that precede definitions are expanded as
definitions of a temporary via (begin EXP (if #f #f)).

* module/ice-9/psyntax.scm (expand-body): Allow mixed definitions and
  expressions.
* module/ice-9/psyntax-pp.scm: Regenerate.
* test-suite/tests/syntax.test: Add a couple tests and update for new
  error messages.
2019-08-25 16:44:07 +02:00
..
ice-9 Allow mixed local definitions and expressions 2019-08-25 16:44:07 +02:00
language Letrectify only on -O2; update docs 2019-08-25 12:51:03 +02:00
oop goops: Fix 'instance?' to work on objects that aren't structs. 2018-08-07 12:05:31 +02:00
rnrs Merge from stable-2.2 2019-08-02 15:04:14 +02:00
scripts Remove redefinition of when & unless in snarf-check-and-output-texi 2019-05-23 17:16:30 +02:00
srfi Merge from stable-2.2 2019-08-02 15:04:42 +02:00
sxml Remove duplicate definitions of call/ec' and let/ec'. 2013-04-06 15:40:19 +02:00
system Unbox floor/ceiling and trigonometric functions where possible 2019-08-24 11:56:18 +02:00
texinfo Merge from stable-2.2 2019-08-02 15:21:59 +02:00
web Merge from stable-2.2 2019-08-02 15:30:13 +02:00
Makefile.am Add letrectify tree-il pass 2019-08-18 22:27:12 +02:00
rnrs.scm Add R6RS bytevector->string, string->bytevector 2016-06-21 11:29:14 +02:00
statprof.scm VM manages hook sets itself 2018-09-14 08:52:24 +02:00
texinfo.scm texinfo: fix @url{@@} parsing 2014-11-09 15:56:33 +00:00