From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from majordomo@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id JAA26730; Thu, 12 Jul 2001 09:14:48 +0200 (MET DST) Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id JAA26725 for ; Thu, 12 Jul 2001 09:14:47 +0200 (MET DST) Received: from ext.lri.fr (ext.lri.fr [129.175.15.4]) by nez-perce.inria.fr (8.11.1/8.10.0) with ESMTP id f6C7Ekb07118 for ; Thu, 12 Jul 2001 09:14:47 +0200 (MET DST) Received: from pc803.lri.fr (IDENT:root@pc803 [129.175.8.114]) by ext.lri.fr (8.11.1/jtpda-5.3.2) with ESMTP id f6C7Ej505306 ; Thu, 12 Jul 2001 09:14:45 +0200 (MET DST) Received: by pc803.lri.fr (8.9.3/feuille) id JAA03520 ; Thu, 12 Jul 2001 09:14:45 +0200 X-Authentication-Warning: localhost.localdomain: filliatr set sender to filliatr@pc803 using -f From: Jean-Christophe Filliatre MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <15181.20069.221159.316790@pc803> Date: Thu, 12 Jul 2001 09:14:45 +0200 (MEST) To: John Eikenberry Cc: caml-list@inria.fr Subject: Re: [Caml-list] ocaml/vim/tags In-Reply-To: <20010711165803.A30954@zhar.net> References: <20010711165803.A30954@zhar.net> X-Mailer: VM 6.49 under Emacs 20.4.1 Reply-To: Jean-Christophe.Filliatre@lri.fr (Jean-Christophe Filliatre) Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk John Eikenberry writes: > > Oh, and I found an example using etags and its regex... but I had little > luck with it either. Seems etags' regex features have changed quite a bit > since 1999/01. I don't know vim, but I'm using the following hack to get tags for Emacs using etags, and it still works nice (of course it is not as satisfactory as tags based on a parsing of ocaml files) ====================================================================== find . -name "*.ml*" | sort -r | xargs \ etags "--regex=/let[ \t]+\([^ \t]+\)/\1/" \ "--regex=/let[ \t]+rec[ \t]+\([^ \t]+\)/\1/" \ "--regex=/and[ \t]+\([^ \t]+\)/\1/" \ "--regex=/type[ \t]+\([^ \t]+\)/\1/" \ "--regex=/exception[ \t]+\([^ \t]+\)/\1/" \ "--regex=/val[ \t]+\([^ \t]+\)/\1/" \ "--regex=/module[ \t]+\([^ \t]+\)/\1/" ====================================================================== The 'sort -r' is used to have .mli entries appearing first, then .ml entries. Indeed, when looking for an identifier, you usually only want its type declaration; if you also want its code, then use C-u M-. Hope this helps, -- Jean-Christophe Filliatre mailto:Jean-Christophe.Filliatre@lri.fr http://www.lri.fr/~filliatr ------------------- Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/ To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr