This is the mail archive of the kawa@sourceware.org mailing list for the Kawa project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: JavaFX unexpected warning


On 10/31/18 4:17 AM, Arie van Wingerden wrote:
Thanks for the tip, works OK now!

So I have to consider two things:

- I can specify type hints in Kawa

I'm this particular case, it seems Kawa should be able to figure out the type of 'button', since
it actually does figure out the type of the Button call.  The complication is that
this is a self-reference: 'button' is referenced in the initializing expression.
To get this to work we have to defer analyzing the arguments to Button until
after we've deduced the type for 'button'.  This is in principle possible,
but may be too complicated.  For one thing it interacts to data flow analysis.
(Everything is tied together and criss-crosses in the "InlineCall" analysis phase.)

This could be fixed if we implemented an optimization which sets the 'button'
variable before we set its fields.  This has a big advantage in that it enables
building self-referential data structures more easily, as well as data structures that
mutually reference each other.  It would have the side-effect of fixing this mini-bug.

I've thought into doing the above optimization, but I don't remember how far I got.
(There are lot of old corners in Kawa.)

Anyway, I'm looking into it.

- and I'll have to get used to the underlying Java api then ;)

'Afraid so.  There is no complete Kawa wrapper around the JavaFX API.
However, Kawa does have a number of convenience features. For example:
https://www.gnu.org/software/kawa/Allocating-objects.html

--
	--Per Bothner
per@bothner.com   http://per.bothner.com/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]