bug-kawa
[Top][All Lists]
Advanced

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

[Bug-kawa] [bug #39940] Class member of type <procedure> compilation exc


From: Per Bothner
Subject: [Bug-kawa] [bug #39940] Class member of type <procedure> compilation exception
Date: Tue, 10 Sep 2013 07:31:05 +0000
User-agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/29.0.1547.65 Safari/537.36

Update of bug #39940 (project kawa):

                  Status:                    None => Fixed                  
             Assigned to:                    None => bothner                
             Open/Closed:                    Open => Closed                 

    _______________________________________________________

Follow-up Comment #1:

This one was tricky, and I ended up checking in a work-around rather than a
proper fix.

The problem is when a context-free lambda is bound to a non-static field. 
I.e. a lambda that does *not* need a closure because it doesn't reference
non-static variables.  Such a field could be static, and the compiler is set
up to optimize such variables to static fields.  The compiler gets confused
when the field is non-static.  I tried fixing this cleanly but failed - there
are a lot of interactions.  (This may be easier to fix if/when we change to
use MethodHandles instead of compiling switches in ModuleBody instances, since
getting rid of the need for ModuleBody will avoid some of the complications.)

Instead I implemented a work-around is mostly right (a little more
conservative than ideal), and which avoids triggering the bug, at least in
cases I've tried.  I checked in this "fix" along with your test-case and some
related tests.

    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?39940>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

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