File tree Expand file tree Collapse file tree 2 files changed +9
-2
lines changed Expand file tree Collapse file tree 2 files changed +9
-2
lines changed Original file line number Diff line number Diff line change @@ -4119,7 +4119,7 @@ f(x) = yt(x)
41194119           (cons (car e)
41204120                 (map-cl-convert (cdr e) fname lam namemap defined toplevel interp opaq globals))))))))
41214121
4122- (define (closure-convert e) (cl-convert e #f #f #f #f  #f #f #f))
4122+ (define (closure-convert e) (cl-convert e #f #f (table) (table)  #f #f #f))
41234123
41244124;;  pass 5: convert to linear IR
41254125
@@ -4403,7 +4403,10 @@ f(x) = yt(x)
44034403                           (else
44044404                            (compile-args (cdr e) break-labels))))
44054405                    (callex (cons (car e) args)))
4406-                (cond (tail (emit-return callex))
4406+                (cond (tail (let ((tmp (make-ssavalue)))
4407+                              ;;  can't just do (emit-return callex), since we might linearize code twice
4408+                              (emit `(= ,tmp ,callex))
4409+                              (emit-return tmp)))
44074410                     (value callex)
44084411                     (else (emit callex)))))
44094412            ((=)
Original file line number Diff line number Diff line change @@ -3276,3 +3276,7 @@ end
32763276    @test  m. Foo. bar ===  1 
32773277    @test  Core. get_binding_type (m. Foo, :bar ) ==  Any
32783278end 
3279+ 
3280+ #  issue 44723
3281+ demo44723 (thunk):: Any  =  Base. Experimental. @opaque  () ->  true  ?  1  :  2 
3282+ @test  demo44723 (7 )() ==  1 
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments