From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by yquem.inria.fr (Postfix) with ESMTP id CB397BC29 for ; Thu, 4 Nov 2004 16:28:10 +0100 (CET) Received: from pauillac.inria.fr (pauillac.inria.fr [128.93.11.35]) by concorde.inria.fr (8.13.0/8.13.0) with ESMTP id iA4FSArX020734 for ; Thu, 4 Nov 2004 16:28:10 +0100 Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id QAA20900 for ; Thu, 4 Nov 2004 16:28:09 +0100 (MET) Received: from rproxy.gmail.com (rproxy.gmail.com [64.233.170.199]) by nez-perce.inria.fr (8.13.0/8.13.0) with ESMTP id iA4FS9vo017966 for ; Thu, 4 Nov 2004 16:28:09 +0100 Received: by rproxy.gmail.com with SMTP id j1so374134rnf for ; Thu, 04 Nov 2004 07:28:06 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:reply-to:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:references; b=EeC8EV+0yyU58ovOA3gKmmfEG8KhxqxeRbUEaUwAKaO+4ORjLxF+AMq3M4agdXr/0NHu21SdY2dNJy7RAWzbPPbfUpqslGtsvQhtR6oWrktJmu8r07wEn0k0H53EB4IGzr+PGmazWUfQOGna5El2to3M7X1vTZkMnC6Y0hwxYco= Received: by 10.38.163.72 with SMTP id l72mr924776rne; Thu, 04 Nov 2004 07:28:06 -0800 (PST) Received: by 10.38.14.54 with HTTP; Thu, 4 Nov 2004 07:28:06 -0800 (PST) Message-ID: Date: Thu, 4 Nov 2004 10:28:06 -0500 From: John Prevost Reply-To: John Prevost To: Thomas Fischbacher Subject: Re: [Caml-list] Arg parsing Cc: caml-list@inria.fr In-Reply-To: Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit References: <20041026201338.GA29858@force.stwing.upenn.edu> X-Miltered: at concorde with ID 418A4A8A.001 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Miltered: at nez-perce with ID 418A4A89.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Spam: no; 0.00; prevost:01 prevost:01 caml-list:01 parsing:01 wrote:01 parses:01 ocaml:01 ocaml:01 parsing:01 struct:01 argv:01 compile:01 argument:01 physik:02 figuring:03 X-Spam-Checker-Version: SpamAssassin 3.0.0 (2004-09-13) on yquem.inria.fr X-Spam-Status: No, score=0.0 required=5.0 tests=RCVD_BY_IP autolearn=disabled version=3.0.0 X-Spam-Level: On Thu, 4 Nov 2004 15:42:47 +0100 (CET), Thomas Fischbacher wrote: > The point is, I have something.ml which I can compile to an application > that parses its own args. Now I want to be able to #use "something.ml" > from within ocaml in such a way that it operates on the extra application > args I passed to the ocaml interpreter without having to change any code. Perhaps if you explained why you want to do this, it would be easier for us to help you. For example, if you're using #use to test out argument parsing code, perhaps this could help you: module Sys = struct include Sys let argv = [| "testprogram"; "my"; "arguments"; "for"; "testing" |] end Other than that, I'm having a *really* hard time figuring out why you would want to examine your command line arguments from an interactive program. John.