On Sat, 04 Apr 2015 21:19:43 +0200, Michael Jones <m...@proclivis.com>  

> I have made a solution to the args problem. To review, if the latest  
> code on github is used on Ubuntu, and if agreements are passed on the  
> command line of the application, wxHaskell does a “getArgs” and passes  
> them on, and then there is an error on the command line. On Windows with  
> the most recent wxWidgets code, it pops a similar dialog.
> To get around the problem, I created startExt, runExt, and argsOnInitExt  
> so that I can pass a [String]. This allows me to filter out agreements  
> not destined for wx.
> I have attached a patch below to show what I did.
> Perhaps one of the developers can give this some consideration. I can  
> certainly post the patch in the bug tracker if desired, just tell me  
> where it is. I am not sure if the one on source forge is in use or not,  
> as the last date is Aug 2014.

The bug tracker on SourceForge is still in use, it has been quiet for a  
while in wxHaskell world.

The patch is not the solution, I wish it were that simple. GHC's run time  
system filters out the RTS parameters, this can be demonstrated with the  
following program (Arguments.hs):

> import System.Environment
> main = getArgs >>= print

The command
   Arguments x +RTS -RTS y
results in:

wxWidgets (at least on Windows) does not use the arguments that are passed  
with wxcAppInitializeC, but reads directly from the argument buffer.

Henk-Jan van Tuyl

What if you could share your unused computer power to help find a cure? In  
just 5 minutes you can join the world's biggest networked computer and get  
us closer sooner. Watch the video.

Haskell programming

Dive into the World of Parallel Programming The Go Parallel Website, sponsored
by Intel and developed in partnership with Slashdot Media, is your hub for all
things parallel software development, from weekly thought leadership blogs to
news, videos, case studies, tutorials and more. Take a look and join the 
conversation now. http://goparallel.sourceforge.net/
wxhaskell-users mailing list

Reply via email to