chicken-janitors
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Chicken-janitors] #1630: Optimizer may incorrectly drop procedure a


From: Chicken Trac
Subject: Re: [Chicken-janitors] #1630: Optimizer may incorrectly drop procedure arguments
Date: Fri, 05 Jul 2019 07:08:25 -0000

#1630: Optimizer may incorrectly drop procedure arguments
---------------------------------+-------------------
            Reporter:  sjamaan   |      Owner:
                Type:  defect    |     Status:  new
            Priority:  major     |  Milestone:  5.2
           Component:  compiler  |    Version:  5.1.0
          Resolution:            |   Keywords:
Estimated difficulty:  medium    |
---------------------------------+-------------------
Description changed by sjamaan:

Old description:

> Found by megane while looking into a patch of mine to improve variable
> replacements:
>
> {{{
> (define (foo bindings)
>   (define (append-map proc lst1)
>     (if lst1
>         (proc 1)
>         (proc 1 2)))
>   (append-map (lambda (b a) (begin)) bindings))
> }}}
>
> Compile this with -O3 and it will error out with this message:
>
> {{{Error: Arguments to inlined call of `a150' do not match parameter-list
> (b a)}}}

New description:

 Found by megane while looking into a patch of mine to improve variable
 replacements:

 {{{
 (define (foo bindings)
   (define (append-map proc lst1)
     (if lst1
         (proc 1)
         (proc 1 2)))
   (append-map (lambda (b a) (begin)) bindings))
 }}}

 Compile this with -O3 and it will error out with this message:

 {{{Error: Arguments to inlined call of `a150' do not match parameter-list
 (b a)}}}

 After fixing this, we can remove the {{{(not captured)}}} test in the
 {{{'replaceable}}} code.

--

--
Ticket URL: <https://bugs.call-cc.org/ticket/1630#comment:1>
CHICKEN Scheme <https://www.call-cc.org/>
CHICKEN Scheme is a compiler for the Scheme programming language.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]