From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: 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 46EF07FCCB for ; Mon, 27 Apr 2015 22:35:18 +0200 (CEST) Received-SPF: None (mail3-smtp-sop.national.inria.fr: no sender authenticity information available from domain of andrew.herron@gmail.com) identity=pra; client-ip=209.85.220.43; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="andrew.herron@gmail.com"; x-sender="andrew.herron@gmail.com"; x-conformance=sidf_compatible Received-SPF: Pass (mail3-smtp-sop.national.inria.fr: domain of andrew.herron@gmail.com designates 209.85.220.43 as permitted sender) identity=mailfrom; client-ip=209.85.220.43; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="andrew.herron@gmail.com"; x-sender="andrew.herron@gmail.com"; 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@mail-pa0-f43.google.com) identity=helo; client-ip=209.85.220.43; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="andrew.herron@gmail.com"; x-sender="postmaster@mail-pa0-f43.google.com"; x-conformance=sidf_compatible X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: A0A3AwAenD5VfivcVdFcg19cgxq0V45XgUgBCYc7ORMBAQEBAQEBEQEBCQsUIS6EIQEBBA8BAhEdAS0MAwwBBQUEIQ8OAgIZGwEFAQoSBgESCwcQh3QBAxEDAgifYYc4PjGKSAEBb4RhiRsWDScDCoUyDBoBBQ6GCIUih3QvgRYFhSwKkCCCP4N5gV+KQId4NYEVXIF/gTxvgkQBAQE X-IPAS-Result: A0A3AwAenD5VfivcVdFcg19cgxq0V45XgUgBCYc7ORMBAQEBAQEBEQEBCQsUIS6EIQEBBA8BAhEdAS0MAwwBBQUEIQ8OAgIZGwEFAQoSBgESCwcQh3QBAxEDAgifYYc4PjGKSAEBb4RhiRsWDScDCoUyDBoBBQ6GCIUih3QvgRYFhSwKkCCCP4N5gV+KQId4NYEVXIF/gTxvgkQBAQE X-IronPort-AV: E=Sophos;i="5.11,659,1422918000"; d="scan'208,217";a="113722985" Received: from mail-pa0-f43.google.com ([209.85.220.43]) by mail3-smtp-sop.national.inria.fr with ESMTP/TLS/RC4-SHA; 27 Apr 2015 22:35:17 +0200 Received: by pacwv17 with SMTP id wv17so119019682pac.0 for ; Mon, 27 Apr 2015 13:35:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:date:from:to:message-id:in-reply-to:references:subject :mime-version:content-type; bh=ifuFp1OOn5x5+y8yQCgA9rD/lCX/1w/CuO7Od31QliI=; b=0QSgq7zw1zhBxxF+kup/Xu/9P4UCNW+2UFdtRrEXyX6jNqdQHf1YSlIAvjeWCmxiPM wrvUY4ZDKJuxXnljV6zd9uUEfNGBhwK1BrU7c+XXDhJASit8TZ7uUaOs7rbVyJcPv00R tyWLohbN6uZwLPhpAPER7eOruET771BbfJZb5AskDWzM4JCrk9PlWXYC7qJlS8s121b7 Y3056/uvaFhiFw/NZdCvPEmRCYUJYQbWU4Q5pc6yoA+FQZZhh0mPgr30+ny8yIpbgoTp gls3xEbl8j7xQeS5pDtM8o9MOrShhMWxJ6is9XPjE97XkneEAMtXuNIo8l7d00yw7eXU CNEQ== X-Received: by 10.70.55.165 with SMTP id t5mr25215146pdp.102.1430166915329; Mon, 27 Apr 2015 13:35:15 -0700 (PDT) Received: from mail.outlook.com (ec2-54-69-102-222.us-west-2.compute.amazonaws.com. [54.69.102.222]) by mx.google.com with ESMTPSA id u8sm20288223pdj.46.2015.04.27.13.35.14 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Mon, 27 Apr 2015 13:35:14 -0700 (PDT) Sender: Andrew Herron Date: Mon, 27 Apr 2015 20:35:13 +0000 (UTC) From: Andrew Herron To: Alain Frisch , caml-list Message-ID: <25B292673A962002.5D4A8FF2-991D-4F1D-8B0E-BA395EBFB8B3@mail.outlook.com> In-Reply-To: <553E7400.60702@lexifi.com> References: <553E7400.60702@lexifi.com> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_3442_2145357380.1430166913758" X-Mailer: Outlook for iOS and Android Subject: Re: [Caml-list] gen_js_api: generating Javascript bindings from OCaml interfaces ------=_Part_3442_2145357380.1430166913758 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit That looks very cool, particularly the @@js preprocessor. I will hopefully have time to try it in the near future. The oscigen list might be interested to hear about this as well :) On Mon, Apr 27, 2015 at 10:38 AM -0700, "Alain Frisch" wrote: Dear all, LexiFi is currently experimenting with the js_of_ocaml compiler in order to create some browser-side applications in OCaml. In this context, we have started a new project called gen_js_api which aims at simplifying the creation of bindings to Javascript libraries. The approach is quite different from js_of_ocaml's native FFI (which relies on language extensions). In gen_js_api, authors of bindings define the expected OCaml interface, annotated with light attributes to define the actual mapping to Javascript; and client of generated bindings work with native OCaml types, without requiring any language extension, nor any knowledge of how js_of_ocaml represents OCaml values in Javascript. gen_js_api has reached a state where actual bindings can be written, and it is reasonably well documented. It is now a good time to look at the project if you're interested in this topic. Of course, feel free to comment on the project or contribute to it. Project page: https://github.com/alainfrisch/gen_js_api Alain -- Caml-list mailing list. Subscription management and archives: https://sympa.inria.fr/sympa/arc/caml-list Beginner's list: http://groups.yahoo.com/group/ocaml_beginners Bug reports: http://caml.inria.fr/bin/caml-bugs ------=_Part_3442_2145357380.1430166913758 Content-Type: text/html; charset=utf-8 Content-Transfer-Encoding: 7bit
That looks very cool, particularly the @@js preprocessor. I will hopefully have time to try it in the near future.

The oscigen list might be interested to hear about this as well :)





On Mon, Apr 27, 2015 at 10:38 AM -0700, "Alain Frisch" <alain.frisch@lexifi.com> wrote:

Dear all,

LexiFi is currently experimenting with the js_of_ocaml compiler in order 
to create some browser-side applications in OCaml. In this context, we 
have started a new project called gen_js_api which aims at simplifying 
the creation of bindings to Javascript libraries.

The approach is quite different from js_of_ocaml's native FFI (which 
relies on language extensions). In gen_js_api, authors of bindings 
define the expected OCaml interface, annotated with light attributes to 
define the actual mapping to Javascript; and client of generated 
bindings work with native OCaml types, without requiring any language 
extension, nor any knowledge of how js_of_ocaml represents OCaml values 
in Javascript.

gen_js_api has reached a state where actual bindings can be written, and 
it is reasonably well documented. It is now a good time to look at the 
project if you're interested in this topic. Of course, feel free to 
comment on the project or contribute to it.

Project page:

   https://github.com/alainfrisch/gen_js_api


Alain

-- 
Caml-list mailing list.  Subscription management and archives:
https://sympa.inria.fr/sympa/arc/caml-list
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners
Bug reports: http://caml.inria.fr/bin/caml-bugs
------=_Part_3442_2145357380.1430166913758--