[cfe-dev] The QtReslot Clang plugin

Kevin Funk via cfe-dev cfe-dev at lists.llvm.org
Fri Feb 17 01:45:52 PST 2017


On Thursday, 16 February 2017 11:24:17 CET Richard Braun via cfe-dev wrote:
> On Wed, Feb 15, 2017 at 05:55:13PM +0000, Sérgio Martins wrote:
> > Beware that the new PMF syntax is not a drop in replacement for the old
> > style. Applying these fixits on a codebase might introduce bugs.
> 
> Yes, the user is clearly made aware of this.
> 
> > Just for fun, can you run your plugin on clazy's unit-tests
> > (clazy/tests/old-style-connect/*.cpp) and compared them to
> > *fixed.cpp.expected, to see if it converted the connects correctly ?
> 
> Well clazy is a lot better it seems. I didn't take care of explicit
> namespaces (although there is a TODO entry about that). QtReslot
> also can't deal with wrong code, it merely converts, so things like
> using SIGNAL() for a slot are caught, and a warning is emitted, but
> nothing more.
> 
> On the other hand, clazy also seems a lot more intrusive, but I suppose
> it's worth it considering the context. I wish I knew it existed and
> could do such conversions before I started QtReslot, although I can't
> give any advice on how to increase awareness about it.

Regarding awareness, I really think we need to work on that a bit. Clazy is 
indeed not discoverable via most of the terms I could come up with when 
googling for a tool *like* Clazy.

E.g.:

- "qt automated refactoring" -> mostly hits about QtCreator
qt automated refactoring
- "qt automated porting" -> Qt4->Qt5 KDAB blog, etc.
- "qt static analysis" -> Qt Creator again
- "qt static analysis clang" -> even there, just hits about Clang SA & QtC

Tips for solutions:

1) Clazy's README [1] needs to be a bit more 'click-baity'. We need to have 
'porting', 'refactoring', 'static', 'analysis', etc. in there. Note an 
introduction is completely missing in that README
2) Scatter more keywords in our blogs about clazy
3) Even more blogging ;)

Cheers,
Kevin

[1] https://phabricator.kde.org/source/clazy/browse/master/README.md

-- 
Kevin Funk | kfunk at kde.org | http://kfunk.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 163 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20170217/175b225b/attachment.sig>


More information about the cfe-dev mailing list