caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Louis Gesbert <louis.gesbert@ocamlpro.com>
To: caml-list@inria.fr, Christophe Raffalli <christophe@raffalli.eu>
Subject: Re: [Caml-list] type keyword indentation with tuareg
Date: Tue, 24 Jan 2017 09:46:12 +0100	[thread overview]
Message-ID: <2754948.nqurzsgqqR@agaric> (raw)
In-Reply-To: <20170123081914.khlfptehb33wmflf@delli7.univ-savoie.fr>

Try ocp-indent (http://opam.ocaml.org/packages/ocp-indent/) for better indentation, based on a token stack rather than regexps. It plugs in to tuareg easily.

(and gives:

    let f : type a.a -> a =
      fun x -> x

)

> - Christophe Raffalli, 23/01/2017 09:19 -
> 
> Hello,
> 
> I search briefly on google and found nothing suprinsingly ... OCaml modern extension
> seems badly supported by tuareg. In particular the type keyword for polymorphic type:
> 
> let f : type a.a -> a =
>           fun x -> x
> 
> Does anyone have a quick fix ?
> 
> Cheers,
> Christophe

  reply	other threads:[~2017-01-24  8:46 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-23  8:19 Christophe Raffalli
2017-01-24  8:46 ` Louis Gesbert [this message]
2017-01-24 11:47   ` Christophe Troestler
2017-01-24 12:35   ` Daniel Bünzli
2017-01-24 13:00     ` Louis Gesbert
2017-01-24 13:10       ` Daniel Bünzli

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=2754948.nqurzsgqqR@agaric \
    --to=louis.gesbert@ocamlpro.com \
    --cc=caml-list@inria.fr \
    --cc=christophe@raffalli.eu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).