Bug 423316

Summary: Implement a check to look for QT_VERSION_CHECK calls below a certain version
Product: [Developer tools] clazy Reporter: martonmiklos <martonmiklosqdev>
Component: generalAssignee: Unassigned bugs mailing-list <unassigned-bugs>
Status: REPORTED ---    
Severity: wishlist CC: smartins
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Other   
OS: All   
Latest Commit: Version Fixed In:

Description martonmiklos 2020-06-21 10:40:07 UTC
This is not a bug report rather than something like thinking out loud:

Many Qt based projects specify a minimum Qt version requirement. As the time moves on this requirement will likely be changed for newer releases. These minimum requirement rise actions makes many Qt version dependent hacks obsolete. Usually these places marked with a QT_VERSION_CHECK macros. It would be useful to have an utility which would list the calls of the QT_VERSION_CHECK macro where called with version number below a certain one. 

What do you think would it be useful to add such a feature to the clazy itself?
Comment 1 Sergio Martins 2020-06-21 14:25:18 UTC
Sounds overkill in clazy, I would just grep for QT_VERSION_CHECK after bumping the required Qt version
Comment 2 martonmiklos 2020-06-21 19:45:30 UTC
(In reply to Sergio Martins from comment #1)
> Sounds overkill in clazy, I would just grep for QT_VERSION_CHECK after
> bumping the required Qt version

Well my goal was adding this check to my CI processes. Handling version numbers properly with grep might be a bit tricky.