I have a program which takes command line argument. The same of source file is encode.ml. I want to load this file in the toplevel.
Is there way to load the source file in the toplevel where we can pass it a command line arguments?
Thanks.
I have a program which takes command line argument. The same of source file is encode.ml. I want to load this file in the toplevel.
Is there way to load the source file in the toplevel where we can pass it a command line arguments?
Thanks.
Yes, invoke your toplevel with
ocaml encode.ml arg1 arg2 etc. The following program demonstrates it: