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 937DE7F8BE for ; Sat, 3 May 2014 18:08:38 +0200 (CEST) Received-SPF: None (mail3-smtp-sop.national.inria.fr: no sender authenticity information available from domain of mmatalka@gmail.com) identity=pra; client-ip=74.125.82.41; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="mmatalka@gmail.com"; x-sender="mmatalka@gmail.com"; x-conformance=sidf_compatible Received-SPF: Pass (mail3-smtp-sop.national.inria.fr: domain of mmatalka@gmail.com designates 74.125.82.41 as permitted sender) identity=mailfrom; client-ip=74.125.82.41; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="mmatalka@gmail.com"; x-sender="mmatalka@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-wg0-f41.google.com) identity=helo; client-ip=74.125.82.41; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="mmatalka@gmail.com"; x-sender="postmaster@mail-wg0-f41.google.com"; x-conformance=sidf_compatible X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Aj0BAH4TZVNKfVIplGdsb2JhbABYgmVwxS6BERYOAQEBAQcLCwkSKoIlAQEEAUABGx0BAwELBgULAxMlDwEEDxEBBQEiE4gsAQMJCAEECJk0jGKDDZklChknDWSFYBEBAQQMjkYHhD8EhFoClFiKfoYFQYRk X-IPAS-Result: Aj0BAH4TZVNKfVIplGdsb2JhbABYgmVwxS6BERYOAQEBAQcLCwkSKoIlAQEEAUABGx0BAwELBgULAxMlDwEEDxEBBQEiE4gsAQMJCAEECJk0jGKDDZklChknDWSFYBEBAQQMjkYHhD8EhFoClFiKfoYFQYRk X-IronPort-AV: E=Sophos;i="4.97,977,1389740400"; d="scan'208";a="60372561" Received: from mail-wg0-f41.google.com ([74.125.82.41]) by mail3-smtp-sop.national.inria.fr with ESMTP/TLS/RC4-SHA; 03 May 2014 18:08:37 +0200 Received: by mail-wg0-f41.google.com with SMTP id z12so514987wgg.24 for ; Sat, 03 May 2014 09:08:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-type; bh=JgzzP004BCbV/Mu1wKOKpyIQmofY4Ig8vFbAW9CT4Uw=; b=o+j/BNtES4tEmFnxG0e/tPVZlNz04qJOan5ZpGb+kelNq4TPcI9Z8WfkWiOFKVSFTF K3/KryT9kCl0FDRYBeTbw6/zhq/xv2XaBGf8EWIjgcYzJ15MeLL9PWmfXlYoqWiM/z+i coiL9j4NqVbbbCpbWt/xZa0PmQFmFrSDh9R71HyYa65vHPKrMJqtdlUknNNUsrUNYaYC LknmzjAmpf9O0QQ91y9rKqy4Ka0KUNnRUhBegd3NKI5RfcgqIP5ARYiZwWj6DiLYA5lB H9Ppk/yLjQZoVYO0XDdn4ue8gNPgdnBgJsf2u12gcUkqgAvuGBeE0JmNm0k224Iplqma wRyg== X-Received: by 10.194.84.101 with SMTP id x5mr7783865wjy.52.1399133317778; Sat, 03 May 2014 09:08:37 -0700 (PDT) Received: from localhost ([2a01:7e00::f03c:91ff:fe70:2696]) by mx.google.com with ESMTPSA id lj15sm4943689wic.13.2014.05.03.09.08.36 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 03 May 2014 09:08:36 -0700 (PDT) From: Malcolm Matalka To: Peter Zotov Cc: caml-list References: <6232dace806569a16f7fbfaa1689ef42@whitequark.org> Date: Sat, 03 May 2014 16:08:35 +0000 In-Reply-To: <6232dace806569a16f7fbfaa1689ef42@whitequark.org> (Peter Zotov's message of "Fri, 02 May 2014 18:29:55 +0400") Message-ID: <87wqe23kvw.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain Subject: Re: [Caml-list] [ANN] ppx_protobuf Nice, great work! I'm not actually a huge fan of mixing type definitions and the protocols they can be encoded/decoded from. How hard would it be to take a module definition accessors on a type and produce a new module with encode/decode functions? That way I could create JSON, XML, Protobufs, etc modules from one module. Just an idea! Peter Zotov writes: > Greetings. > > I have just released the first version of ppx_protobuf, a complete > Protocol Buffers implementation. Unlike Google's implementation, > ppx_protobuf derives the message structure directly from OCaml type > definitions, which allows a much more seamless integration with > OCaml's types. In particular, ppx_protobuf natively supports > sum types, while maintaining full backwards compatibility with > protoc. > > ppx_protobuf uses the extension points API, and thus requires > a recent (>= 2014-04-29) 4.02 (trunk) compiler. It also requires > an unreleased version of ppx_tools. It is probably easiest > to install both from the source repositories[1][2]. > > The API is extensively documented at [3]. > > [1]: https://github.com/whitequark/ocaml-ppx_protobuf.git > [2]: https://github.com/alainfrisch/ppx_tools.git > [3]: https://github.com/whitequark/ocaml-ppx_protobuf/blob/master/README.md > > -- > WBR, Peter Zotov.