[wg-camlp4] [Caml-devel] Structure/signature attributes suggestion

Alain Frisch alain.frisch at lexifi.com
Mon Apr 14 16:47:43 BST 2014


On 04/14/2014 05:40 PM, Damien Doligez wrote:
> IIUC, we now have three kinds of attributes:
>
> [@foo]   attached to an expression
> [@@foo]  attached to a structure item
> [@@@foo] attached to the whole module (with location being significant?)

[@@@foo] is part of the flow of structure items.  An application can 
certainly interpret it as attached to the whole unit (or just the 
current structure), but in general the location is significant.  This is 
the case in particular for [@@warning] which you can use several times 
in the same unit; and it applies only from the point it appears.


Alain


More information about the wg-camlp4 mailing list