From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Original-To: caml-list@sympa.inria.fr Delivered-To: caml-list@sympa.inria.fr Received: from mail3-relais-sop.national.inria.fr (mail3-relais-sop.national.inria.fr [192.134.164.104]) by sympa.inria.fr (Postfix) with ESMTPS id 96F987F0AB for ; Thu, 23 Mar 2017 16:09:48 +0100 (CET) Authentication-Results: mail3-smtp-sop.national.inria.fr; spf=None smtp.pra=francois.bobot@cea.fr; spf=Pass smtp.mailfrom=francois.bobot@cea.fr; spf=None smtp.helo=postmaster@cirse-smtp-out.extra.cea.fr Received-SPF: None (mail3-smtp-sop.national.inria.fr: no sender authenticity information available from domain of francois.bobot@cea.fr) identity=pra; client-ip=132.167.192.148; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="francois.bobot@cea.fr"; x-sender="francois.bobot@cea.fr"; x-conformance=sidf_compatible Received-SPF: Pass (mail3-smtp-sop.national.inria.fr: domain of francois.bobot@cea.fr designates 132.167.192.148 as permitted sender) identity=mailfrom; client-ip=132.167.192.148; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="francois.bobot@cea.fr"; x-sender="francois.bobot@cea.fr"; x-conformance=sidf_compatible; x-record-type="v=spf1" Received-SPF: None (mail3-smtp-sop.national.inria.fr: no sender authenticity information available from domain of postmaster@cirse-smtp-out.extra.cea.fr) identity=helo; client-ip=132.167.192.148; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="francois.bobot@cea.fr"; x-sender="postmaster@cirse-smtp-out.extra.cea.fr"; x-conformance=sidf_compatible IronPort-PHdr: =?us-ascii?q?9a23=3AjCfFWRCUPsxsV/iL3IdeUyQJP3N1i/DPJgcQr6Af?= =?us-ascii?q?oPdwSPv+osbcNUDSrc9gkEXOFd2CrakV16yO6+jJYi8p2d65qncMcZhBBVcuqP?= =?us-ascii?q?49uEgeOvODElDxN/XwbiY3T4xoXV5h+GynYwAOQJ6tL1LdrWev4jEMBx7xKRR6?= =?us-ascii?q?JvjvGo7Vks+7y/2+94fdbghMizexe69+IAmrpgjNq8cahpdvJLwswRXTuHtIfO?= =?us-ascii?q?pWxWJsJV2Nmhv3+9m98p1+/SlOovwt78FPX7n0cKQ+VrxYES8pM3sp683xtBnM?= =?us-ascii?q?VhWA630BWWgLiBVIAgzF7BbnXpfttybxq+Rw1DWGMcDwULs5Xymp4aV2Rx/ykC?= =?us-ascii?q?oJKiA38G/XhMJzgqxUrh2uqB5jzIDbe4yVKPlzc7nBcd8GS2dMXMBcXDFBDIOm?= =?us-ascii?q?aIsPCvIMM+ZCr4bnoVsJtRy+BQi3BOz31zJIgWT53aom0+88FgzG0hYgEMgIsH?= =?us-ascii?q?vIq9X1NbwSXfquw6nP1jrDaO9W1Czh54fWaB8tu/+MXahpfMfX1EIhFBvFg02N?= =?us-ascii?q?pYHrIT+ZzPkBvmmZ4uZ6SO6ij3ArpxtsrjWgxcogkpTFi4wLxlze6Cl0wYc4Kc?= =?us-ascii?q?elREN/f9KoCplduieHPIVsWMwiWXtnuCMix70Gp5G7eC8KxYw7yB7ecfyHaJaH?= =?us-ascii?q?7gv4VOaUPTd4nGtpeLWihxau60Sv1OL9VtWu0FlQtCZKjsfDuWoX2xzd8MiLUv?= =?us-ascii?q?p9/kG/1jaTzw3f9+9JLV4umabGKpMswKQ8mocXvEjdBCP6hUr7gayOekUh4Oeo?= =?us-ascii?q?6uDnYrv8pp+bMo95kg/+Mr40lcy5Hes4NQkOX3OB9eun073s5kr5QKlRg/IqjK?= =?us-ascii?q?bWqorWJcoBpqKhGQ9azp4j6wqjDzehyNkXgWMILFdBeB6ei4jpOkrOIOzjAPek?= =?us-ascii?q?g1WslS9ryOrcMr3gBJXNNHnDn637cbZz8U4PgDY0mNtW4pYRDrAaPNryXFXwvZ?= =?us-ascii?q?rWFEwXKQuxlsj9AdPy0YIFbkiICKiFePfcq1aO7eUuOK+GY4USpB72JvFj6eS4?= =?us-ascii?q?3ixxokMUYaT8hchfU3u/BPkze0g=3D?= X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: =?us-ascii?q?A0COAgD349NYh5TAp4RdHAEBBAEBCgEBF?= =?us-ascii?q?wEBBAEBCgEBhAeBC4NiiwKQPZd2IoYAAoMVQxQBAQEBAQEBAQEBARIBAQEKCwk?= =?us-ascii?q?IKC+CMyCCQwMDIw8BBVELGgImAgJXEwYCAQGKAqp2giaKPTKBC4dICIJihSCCO?= =?us-ascii?q?oJfBZxVa4YQjh6ICoZWk2I2gSU6I1KEaYFwdAGKCAEBAQ?= X-IPAS-Result: =?us-ascii?q?A0COAgD349NYh5TAp4RdHAEBBAEBCgEBFwEBBAEBCgEBhAe?= =?us-ascii?q?BC4NiiwKQPZd2IoYAAoMVQxQBAQEBAQEBAQEBARIBAQEKCwkIKC+CMyCCQwMDI?= =?us-ascii?q?w8BBVELGgImAgJXEwYCAQGKAqp2giaKPTKBC4dICIJihSCCOoJfBZxVa4YQjh6?= =?us-ascii?q?ICoZWk2I2gSU6I1KEaYFwdAGKCAEBAQ?= X-IronPort-AV: E=Sophos;i="5.36,210,1486422000"; d="scan'208";a="217791071" Received: from cirse-smtp-out.extra.cea.fr ([132.167.192.148]) by mail3-smtp-sop.national.inria.fr with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 23 Mar 2017 16:09:47 +0100 Received: from pisaure.intra.cea.fr (pisaure.intra.cea.fr [132.166.88.21]) by cirse-sys.extra.cea.fr (8.14.7/8.14.7/CEAnet-Internet-out-4.0) with ESMTP id v2NF9l02026836 for ; Thu, 23 Mar 2017 16:09:47 +0100 Received: from pisaure.intra.cea.fr (localhost [127.0.0.1]) by localhost (Postfix) with SMTP id 99215206D90 for ; Thu, 23 Mar 2017 16:09:47 +0100 (CET) Received: from muguet2.intra.cea.fr (muguet2.intra.cea.fr [132.166.192.7]) by pisaure.intra.cea.fr (Postfix) with ESMTP id 85BBE206D81 for ; Thu, 23 Mar 2017 16:09:47 +0100 (CET) Received: from [10.8.35.73] (is231324.intra.cea.fr [10.8.35.73]) by muguet2.intra.cea.fr (8.15.2/8.15.2/CEAnet-Intranet-out-1.4) with ESMTP id v2NF9l2C025775 for ; Thu, 23 Mar 2017 16:09:47 +0100 To: caml-list@inria.fr References: <1590236478.9253508.1490261850094.JavaMail.zimbra@edu.univ-fcomte.fr> From: =?UTF-8?Q?Fran=c3=a7ois_Bobot?= Message-ID: Date: Thu, 23 Mar 2017 16:09:47 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.7.0 MIME-Version: 1.0 In-Reply-To: <1590236478.9253508.1490261850094.JavaMail.zimbra@edu.univ-fcomte.fr> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Subject: Re: [Caml-list] [Question] Loading .ml in memory to interact with them. Le 23/03/2017 à 10:37, paul.lachat@edu.univ-fcomte.fr a écrit : > I need to find a way to put Ocaml program in memory so I could interact with the program > (call function, get result, find information about the variables, ...) without always reading the file. > > That what append when we use the directive #use "file.ml";; in the interactive shell (the toplevel, > when you type the command ocaml in a shell). > > The instruction need to come from a Matlab function. So, I was thinking to create a process who run > the ocaml command, > redirect his standard input in a named pipe, redirect his standard output in another named pipe, so > I could send instructions and received responses. You can also try to embed the ocaml interpreter inside the Matlab process directly. The ocaml compilers libs gives an easy way to control the interpreter: call function, get result, find information about the variables, ... . I imagine you could connect it t matlab with a C-binding. Best, -- François