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 mail4-relais-sop.national.inria.fr (mail4-relais-sop.national.inria.fr [192.134.164.105]) by sympa.inria.fr (Postfix) with ESMTPS id 135677EC41 for ; Thu, 18 Oct 2012 02:31:33 +0200 (CEST) Received-SPF: None (mail4-smtp-sop.national.inria.fr: no sender authenticity information available from domain of bobzhang1988@gmail.com) identity=pra; client-ip=209.85.223.182; receiver=mail4-smtp-sop.national.inria.fr; envelope-from="bobzhang1988@gmail.com"; x-sender="bobzhang1988@gmail.com"; x-conformance=sidf_compatible Received-SPF: Pass (mail4-smtp-sop.national.inria.fr: domain of bobzhang1988@gmail.com designates 209.85.223.182 as permitted sender) identity=mailfrom; client-ip=209.85.223.182; receiver=mail4-smtp-sop.national.inria.fr; envelope-from="bobzhang1988@gmail.com"; x-sender="bobzhang1988@gmail.com"; x-conformance=sidf_compatible; x-record-type="v=spf1" Received-SPF: None (mail4-smtp-sop.national.inria.fr: no sender authenticity information available from domain of postmaster@mail-ie0-f182.google.com) identity=helo; client-ip=209.85.223.182; receiver=mail4-smtp-sop.national.inria.fr; envelope-from="bobzhang1988@gmail.com"; x-sender="postmaster@mail-ie0-f182.google.com"; x-conformance=sidf_compatible X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AuIEACxNf1DRVd+2m2dsb2JhbABFrmSIcYdbAnwIIwEBAQEBCAkLCRQngiABAQEDARICLAEbHQEDAQsGBQQBBg0uIgERAQUBHAYTIodPAQMJBp0zCQOMKIJ2hR4KGScNWYh1AQUMi0yBaIRaA5VrgRWNPhYphC0 X-IronPort-AV: E=Sophos;i="4.80,603,1344204000"; d="scan'208";a="159411590" Received: from mail-ie0-f182.google.com ([209.85.223.182]) by mail4-smtp-sop.national.inria.fr with ESMTP/TLS/RC4-SHA; 18 Oct 2012 02:31:32 +0200 Received: by mail-ie0-f182.google.com with SMTP id k10so21650089iea.27 for ; Wed, 17 Oct 2012 17:31:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=61dxlfbf7x0aMJzYzwydGmebqTww2AbQH06OOBpNVrg=; b=KWkvl9Yv9frb9lNgDPPuuSUbGBaS4akl9m5NBVGMH10o2W2UuUVGShOJEy/eD67huj nWxYGYyyU0SV18hnPmhQSZeQmWUAyOyjjkJJ0jWKaOo70UH8QzD0boWY7F3Pcn9o/irQ 4A0mwWe5hbDoU1/6MaekUlPkaCWJEGliDaXep8u6au7Ye4HuhfszMVTpdAkaIyj4ZWQR YdU4JclO178HYLdayIrbR7HyngZGJiOnrqu391FtIuznmuLt/bI3B0CyJe7qLfEpbI1r F37G4d9Z2del5SbIZZA1NkWAoTqAAxfsDSLzWqFlGwoHP3caQtJXe4gEbrNjAgorgFuv EBGg== MIME-Version: 1.0 Received: by 10.50.0.193 with SMTP id 1mr3368310igg.0.1350520290401; Wed, 17 Oct 2012 17:31:30 -0700 (PDT) Received: by 10.64.17.4 with HTTP; Wed, 17 Oct 2012 17:31:30 -0700 (PDT) In-Reply-To: <507EDAB4.7040302@frisch.fr> References: <503A9815.7000103@gmail.com> <503B3818.1050503@frisch.fr> <507EDAB4.7040302@frisch.fr> Date: Wed, 17 Oct 2012 20:31:30 -0400 Message-ID: From: bob zhang To: Alain Frisch Cc: Caml List Content-Type: multipart/alternative; boundary=e89a8f502f8e2bddbc04cc4a82e7 Subject: Re: [Caml-list] Is there a printer for ocaml's parsetree --e89a8f502f8e2bddbc04cc4a82e7 Content-Type: text/plain; charset=ISO-8859-1 Hi Alain, that's really cool, thanks! On Wed, Oct 17, 2012 at 12:20 PM, Alain Frisch wrote: > On 08/27/2012 11:04 AM, Alain Frisch wrote: > >> There is a printer in tools/pprintast.ml. It would be useful to >> integrate it to the ocaml compilers, with an option to tell them to dump >> the (preprocessed) parsetree in source form. >> > > This is now available in the trunk, with a new command-line option > "-dsource". The pretty-printer in source form needs some polishing > (formatting, and missing features in the AST). Contribution to improve it > are welcome! > > -- Alain > -- Regards -- Bob --e89a8f502f8e2bddbc04cc4a82e7 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Hi Alain, that's really cool, thanks!

On Wed, Oct 17, 2012 at 12:20 PM, Alain Frisch <alain@frisch.fr> wrote:
On 08/27/2012 11:04 AM, Al= ain Frisch wrote:
There is a printer in tools/pprintast.ml. =A0It would be useful to
integrate it to the ocaml compilers, with an option to tell them to dump
the (preprocessed) parsetree in source form.

This is now available in the trunk, with a new command-line option "-d= source". =A0The pretty-printer in source form needs some polishing (fo= rmatting, and missing features in the AST). =A0Contribution to improve it a= re welcome!

-- Alain



--
Regards
-- Bob
--e89a8f502f8e2bddbc04cc4a82e7--