Opened 8 years ago

Closed 8 years ago

#1080 closed defect (fixed)

condition-case expands into two else clauses

Reported by: Christian Kellermann Owned by:
Priority: major Milestone: 4.9.0
Component: unknown Version: 4.8.x
Keywords: syntax condition-case compiler Cc:
Estimated difficulty:

Description

When expanding the following you can see the second else clause. The compiler in current master warns about this:

#;2> ,x (condition-case 'something ((exn some thing) 'foo) (exn () 'bar))
((call-with-current-continuation
   (##core#lambda
     (k)
     (with-exception-handler
       (##core#lambda
         (exvar)
         (k (##core#lambda
              ()
              (##core#let
                ((kvar (and (##sys#structure? exvar (##core#quote condition))
                            (##sys#slot exvar 1))))
                (cond ((and kvar
                            (memv (##core#quote exn) kvar)
                            (memv (##core#quote some) kvar)
                            (memv (##core#quote thing) kvar))
                       (##core#let () 'foo))
                      (else (##core#let ((exn exvar)) 'bar))
                      (else (##sys#signal exvar)))))))
       (##core#lambda
         ()
         (##sys#call-with-values
           (##core#lambda () 'something)
           (##core#lambda
             args
             (k (##core#lambda () (##sys#apply ##sys#values args))))))))))

Change History (1)

comment:1 Changed 8 years ago by Christian Kellermann

Resolution: fixed
Status: newclosed

Fixed in master with commit b504261

Note: See TracTickets for help on using tickets.