Version française
Home     About     Download     Resources     Contact us    
Browse thread
lex: including regex definitions from a separate file
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Richard Jones <rich@a...>
Subject: Re: [Caml-list] lex: including regex definitions from a separate file
On Mon, Nov 19, 2007 at 03:29:16PM -0500, Sam Steingold wrote:
> I have several lexers in the same directory and I want them to share the
> regexp definitions.
> is there a way to put the regexp definitions in foo.mll and include them
>  in bar.mll?

Probably your best bet is to preprocess bar.mll in a Makefile -- eg.
using cpp or m4 to generate the file from an input 'bar.mll.in'.

Rich.

-- 
Richard Jones
Red Hat