Changeset 14268 in project for chicken


Ignore:
Timestamp:
04/16/09 11:34:25 (10 years ago)
Author:
felix winkelmann
Message:

fixed keyword var resolve bug reported by Alonso Andres (#7)

Location:
chicken/trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • chicken/trunk/TODO

    r14133 r14268  
    5858*** should run without installation
    5959
     60** setting nursery default size doesn't seem to work properly (reported by Zbigniew)
     61
    6062
    6163* tasks
     
    9294**** option in chicken-install to list available eggs
    9395*** automatically update db after extension installation?
    94 *** test sudo
    9596
    9697** library units
     
    121122* wiki
    122123
    123 ** XXX update egg tutorials
    124 ** XXX compatibility page
     124** compatibility page
    125125
    126126
     
    128128
    129129** check status of `s48-modules'
    130 ** implement script to generate RSS feed from egg-index and install on galinha
    131130
    132131
     
    143142** document new .meta entries in tutorials on wiki
    144143   depends, test-depends
    145 ** chicken.texi needs to be regenerated
    146144
    147145
  • chicken/trunk/expand.scm

    r14236 r14268  
    391391            (%let-optionals* (macro-alias 'let-optionals* se))
    392392            (%let (macro-alias 'let se)))
    393         (let loop ([mode 0]             ; req, opt, rest, key, end
     393        (let loop ([mode 0]             ; req=0, opt=1, rest=2, key=3, end=4
    394394                   [req '()]
    395395                   [opt '()]
     
    428428                     (err "rest argument list specified more than once")
    429429                     (begin
    430                        (if (not rvar) (set! rvar llist))
     430                       (unless rvar (set! rvar llist))
    431431                       (set! hasrest llist)
    432432                       (loop 4 req opt '() '()) ) ) ]
     
    435435                [else
    436436                 (let* ((var (car llist))
    437                         (x (or (and (symbol? var) (lookup var se)) var))
     437                        (x (or (and (symbol? var) (not (eq? 3 mode)) (lookup var se)) var))
    438438                        (r (cdr llist)))
    439439                   (case x
    440440                     [(#!optional)
    441                       (if (not rvar) (set! rvar (macro-alias 'tmp se)))
     441                      (unless rvar (set! rvar (macro-alias 'tmp se)))
    442442                      (if (eq? mode 0)
    443443                          (loop 1 req '() '() r)
  • chicken/trunk/tests/syntax-tests.scm

    r14236 r14268  
    305305(assert (equal? (foo (1 2) (3) (5 6)) '(((1 2)) ((3)) ((5 6))))) ; failed
    306306(assert (equal? (foo 1) '((1))))
     307
     308
     309;;; incorrect lookup for keyword variables in DSSSL llists
     310
     311(module broken-keyword-var ()
     312  (import scheme chicken)
     313  ((lambda (#!key string) (assert (not string))))) ; refered to R5RS `string'
Note: See TracChangeset for help on using the changeset viewer.