[MLton-user] Path of Executable

Henry Cejtin henry.cejtin at sbcglobal.net
Mon Jan 15 06:49:16 PST 2007

Like I said before, it definitely is NOT always true that argv[0] (A.K.A.
CommandLine.name ()) is the current command being executed.  At the very least,
you have to do the search using the PATH environment variable if it is not
an absolute path.  Even that is just a convention.  One can exec any command
with argv[0] being any thing you want it to be.  Even just looking at the
shell, if you run a shell file, the executable is the shell, but argv[0] is
set to the name of the shell file.

More information about the MLton-user mailing list