Typz added a comment.

In https://reviews.llvm.org/D37813#1184051, @klimek wrote:

> The problem here is that we have different opinions on how the formatting on 
> namespace macros should behave in the first place- I think they should behave 
> like namespaces, you want them to be formatted differently.
>  Given that you want full control over the formatting of those macros, and 
> them not actually be formatted exactly like namespaces or classes, I think we 
> need a more generic mechanism for you to express that.


Not sure what you mean here. I want them to behave like namespaces as well, 
this is actually the use case I have... As implemented, they indeed behave 
exactly like namespaces :

  TESTSUITE(a) {                       namespace a {
  } // TESTSUITE(a)                    } // namespace a
                                  VS
  TESTSUITE(a) { TESTSUITE(b) {        namespace a { namespace b {
  } // TESTSUITE(a::b)                 }} // namespace a::b

(as long as there is a single argument. When multiple arguments are used, I add 
to choose a heuristic...)

As far as I understand, the divergence is that you would want something to 
"match" the implementation of the macro, while I propose a simpler heuristic, 
which should work fine for namespaces...


Repository:
  rC Clang

https://reviews.llvm.org/D37813



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to