clang-format pointer binding patch

Daniel Jasper djasper at google.com
Mon Jun 16 06:29:58 PDT 2014


Thank you for working on this. This was started and abandoned (?) before:
http://lists.cs.uiuc.edu/pipermail/cfe-commits/Week-of-Mon-20131007/090583.html
(It is quite old, but might be worth reading up on, I had a few comments).

As for this patch:
- We now have a code review system at reviews.llvm.org. If at all possible,
I'd like to do the actual code review there.
- At some stage we discussed that it really is "PointerAlignment" and not
"PointerBinding", so if we are renaming this already, lets fix this as well.
- We should try to make this backwards compatible, so clang-format should
still accept the old settings in the configuration file. For an example of
a bool that was changed to an enum see UseTabStyle. I am not quite sure how
to map two different configuration names ("PointerBindsToType" and
"PointerAlignment") to the same variable, but I am happy to do the renaming
as a follow up patch if you can't figure it out.
- We need more tests, copy more of the .."UsesOfStarAndAmp" tests.
- The enumerator names aren't really ideal as there isn't always a
"variable". I liked the "Left", "Right" and "Middle" from the other patch.



On Mon, Jun 16, 2014 at 2:30 PM, Sobczak, Janusz <janusz.sobczak at mobica.com>
wrote:

> Hi
>
> The patch implements 3 types of pointer bindings:
> type *var;
> type* var;
> type * var;
>
> Feature requested in bug 19929.
>
> Cheers,
> Janusz
>
> _______________________________________________
> cfe-commits mailing list
> cfe-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20140616/bcde84f1/attachment.html>


More information about the cfe-commits mailing list