So, I'm using a library that calls Arg.parse to build up it's inputs in another data structure. I don't want to rewrite any code, and I'm consuming the library in a different way than how the binary consumes it, which is just to feed it input from the command line. Not wanting to replicate code in two locations, I chose to use Arg.parse_argv, and supplied it with an array that would normally be on the command line. For some reason, supplying the exact same speclist as what was used in the original statement that works as a command line tool doesn't result in the parameters being parsed. command line tool: Arg.parse speclist anon usage; get_program () (* consumes the mutable list that speclist modified *) (* speclist modifies a mutable list used to hold arguments *) my code that consumes speclist as a library: Arg.parse_argv custom_arguments speclist anon usage get_program () (* exact same function as above, exact same variables to Arg.parse* *) For some reason, Arg.parse_argv seems to complete, but when get_program proceeds, it sees the mutable argument list as being empty. Why?