From: Blair A. <mrb...@gm...> - 2013-06-14 17:42:58
|
Ah I see. I'm still looking through the wxHaskell code to see if there is any work I think I can do (as a beginner!) and thought id give this a mention. I agree that SWIG is a great tool! Hopefully they get their summer of code working. Many thanks, Blair On 14 June 2013 15:02, Jeremy O'Donoghue <jer...@gm...> wrote: > From the website... > > "To use fficxx, you write a Haskell model of the C++ public interfaces > and fficxx generates both a C wrapper and associated haskell functions and > type classes which reflect specified model of the C++ interfaces. It is > currently the user’s responsibility to specify a correct model of the C++ > interfaces, because fficxx does not presently check for model correctness." > > This is the opposite of what you need for wxHaskell - the ideal scenario > is to parse the C++ headers and use them to generate Haskell bindings > automatically. Writing correct Haskell representations of the complete > wxWidgets API will be very painful and is likely to be error-prone (it is > quite a large API). > > There are a few key things that any automated binding generator needs to > handle: > * Callback functions - these are used extensively in wxWidgets; > * Memory management - the approach in wxHaskell today is not completely > satisfactory and there are quite a few memory leaks. > > I believe that the only game in town which is really sufficiently mature > is SWIG - wxPython bindings are already generated by SWIG, so it is known > to be fit for purpose. If the Haskell Qt binding generator goes in this > direction, it may well be what is needed. > > Regards > Jeremy > > > On 14 June 2013 10:27, Eric Kow <eri...@gm...> wrote: > >> Seems like something the author would be very interested in testing on. >> I think the wxHaskell paper talks about how it's done here >> http://research.microsoft.com/pubs/66810/wxhaskell.pdf >> >> On 13 June 2013 20:43, Blair Archibald <mrb...@gm...> >> wrote: >> > Hi guys, >> > >> > Did anyone see this new C++ foreign function generator mentioned in the >> > haskell weekly news. >> > >> > http://ianwookim.org/fficxx/ >> > >> > At the moment the lack of documentation puts me off, but something like >> this >> > could be the end of some of our generation problems. In my mind it's >> great >> > that people are working on this sorta thing! >> > >> > I might look into this deeper at the weekend and see if I could use it >> to >> > generate wx bindings. >> > >> > Many thanks, >> > Blair >> > >> > >> > >> > >> > >> ------------------------------------------------------------------------------ >> > This SF.net email is sponsored by Windows: >> > >> > Build for Windows Store. >> > >> > http://p.sf.net/sfu/windows-dev2dev >> > _______________________________________________ >> > wxhaskell-devel mailing list >> > wxh...@li... >> > https://lists.sourceforge.net/lists/listinfo/wxhaskell-devel >> > >> >> >> >> -- >> Eric Kow <http://erickow.com> >> >> >> ------------------------------------------------------------------------------ >> This SF.net email is sponsored by Windows: >> >> Build for Windows Store. >> >> http://p.sf.net/sfu/windows-dev2dev >> _______________________________________________ >> wxhaskell-devel mailing list >> wxh...@li... >> https://lists.sourceforge.net/lists/listinfo/wxhaskell-devel >> > > |