Version française
Home     About     Download     Resources     Contact us    

This site is updated infrequently. For up-to-date information, please visit the new OCaml website at

Browse thread
[Caml-list] camlp4 'loc' variable
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2004-02-22 (18:58)
From: Stefano Zacchiroli <zack@b...>
Subject: Re: [Caml-list] camlp4 'loc' variable
On Sun, Feb 22, 2004 at 01:06:47PM -0500, J. Garrett Morris wrote:
> which are used both in antiquotations and in let statements
> surrounding expr quotations ... when do I need to take 'loc' as a
> parameter?

The camlp4 manual states that the loc variable is bound in the "action"
part of a "level-rules" (i.e. the right hand side of an -> arrow in a
grammar production).

Therefore I guess you should pass loc as a parameter if you invoke
functions from those RHSs which are not defined inside a RHS.


Stefano Zacchiroli -*- Computer Science PhD student @ Uny Bologna, Italy
zack@{,,} -%-
If there's any real truth it's that the entire multidimensional infinity
of the Universe is almost certainly being run by a bunch of maniacs. -!-

To unsubscribe, mail Archives:
Bug reports: FAQ:
Beginner's list: