Bug 353766

Summary: Find detachments on temporaries made by operator[]
Product: [Developer tools] clazy Reporter: Sergio Martins <smartins>
Component: generalAssignee: Sergio Martins <smartins>
Status: RESOLVED FIXED    
Severity: wishlist    
Priority: NOR    
Version First Reported In: unspecified   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Sergio Martins 2015-10-10 17:40:27 UTC
For example: getList()[0]

Reproducible: Always
Comment 1 Sergio Martins 2015-10-19 22:39:13 UTC
Git commit 9475e638630ccfcf7923e00113f64d50a94fe9a3 by Sergio Martins.
Committed on 19/10/2015 at 22:38.
Pushed by smartins into branch 'master'.

detaching-temporary: Also warn for operator[]

M  +10   -1    Utils.cpp
M  +10   -8    checks/detachingtemporary.cpp
M  +9    -0    tests/detaching-temporary/main.cpp
M  +3    -0    tests/detaching-temporary/test.expected

http://commits.kde.org/clazy/9475e638630ccfcf7923e00113f64d50a94fe9a3