Addition to unix: raw ByteString APIs

Evan Laforge qdunkan at
Fri Nov 11 18:16:48 CET 2011

>      - There is a new function
>         System.Posix.ByteString.getArgs :: [ByteString]
>        returning the raw untranslated arguments as passed to exec()
>        when the program was started.

Is this one similar to the [String] getArgs in that it drops unix's
argv[0]?  I was recently surprised by that in the standard getArgs
because I wanted a program to restart itself.  I can't figure out how
to do that without access to argv[0].

I suppose for consistency the ByteString version should have the same
behaviour, so maybe this is just an opportunity to wonder why it does
that in the first place.

More information about the Libraries mailing list