[wg-camlp4] [Caml-devel] Built-in attributes

Gabriel Scherer gabriel.scherer at gmail.com
Mon Apr 14 22:58:06 BST 2014


I'm not convinced this is the good change.
- I see the point of namespacing to avoid conflicts but I suspect
conciseness is also important here, if we want to use warning-tweaking
directives in a fine-grained enough way
- I suspect that the idea of warning over unknown ocaml.foo attributes is
papering over the real difficulty, which is the fact that it's very easy to
make a mistake if warnings are ignored by default. While giving more
structure to an "ocaml" namespace solves the particular problem Damien had
with deprecated, chances are users will still have their problems with the
warnings they define on their own (or what about [@@OCaml.warning]). We may
want to think harder about resilience to user mistakes to aim for a less
ad-hoc solution.


On Mon, Apr 14, 2014 at 5:18 PM, Alain Frisch <alain.frisch at lexifi.com>wrote:

> Dear all,
>
> In order to mark cleanly which warnings are understood in a special way by
> the compiler, I've added an ocaml.* prefix to them.   Currently, the only
> such attributes are ocaml.deprecated and ocaml.warning.
>
> I'm planning to add (with a low priority) a new warning to report uses of
> unknown ocaml.* warnings (or known warnings applied to a wrong object).
>  This will allow to catch typos such as writing ocaml.warnings instead of
> ocaml.warning.
>
>
> Alain
>
> _______________________________________________
> Caml-devel mailing list
> Caml-devel at yquem.inria.fr
> http://yquem.inria.fr/cgi-bin/mailman/listinfo/caml-devel
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ocaml.org/pipermail/wg-camlp4/attachments/20140414/f20a9d88/attachment.html>


More information about the wg-camlp4 mailing list