llvm-project/clang-tools-extra/test
Alexander Kornienko ebdfb9cf0c [Clang-tidy] check for malloc, realloc and free calls
Summary:
This checker flags the use of C-style memory management functionality and notes about modern alternatives.
In an earlier revision it tried to autofix some kind of patterns, but that was a bad idea. Since memory management can be so widespread in a program, manual updating is most likely necessary.
Maybe for special cases, there could be later additions to this basic checker.

This is the first checker I wrote and I never did something with clang (only compiling programs). So whenever I missed conventions or did plain retarded stuff, feel free to point it out! I am willing to fix them and write a better checker.

I hope the patch does work, I never did this either. On a testapply in my repository it did, but I am pretty unconfident in my patching skills :)

Reviewers: aaron.ballman, hokein, alexfh, malcolm.parsons

Subscribers: cfe-commits, JDevlieghere, nemanjai, Eugene.Zelenko, Prazek, mgorny, modocache

Tags: #clang-tools-extra

Differential Revision: https://reviews.llvm.org/D26167

Patch by Jonas Toth!

llvm-svn: 289546
2016-12-13 16:38:18 +00:00
..
Unit Replace hardcoded comment at 'lit.site.cfg.in' 2016-04-16 07:01:42 +00:00
change-namespace [change-namespace] don't generate replacements for files that don't match file pattern. 2016-12-01 17:25:55 +00:00
clang-apply-replacements Handle newlines on Windows correctly. 2014-12-09 02:57:56 +00:00
clang-move [clang-move] Fix not moving using-decls in global namespace in old.cc 2016-11-18 10:51:16 +00:00
clang-query Add a makefile for clang-query. Patch by Alex Horn! 2014-02-18 19:46:01 +00:00
clang-rename [clang-rename] Add test case for r287758. 2016-11-23 13:14:19 +00:00
clang-reorder-fields Add clang-reorder-fields to clang-tools-extra 2016-09-02 02:56:07 +00:00
clang-tidy [Clang-tidy] check for malloc, realloc and free calls 2016-12-13 16:38:18 +00:00
include-fixer [include-fixer] Don't skip repeated lookups in plugin mode. 2016-11-30 14:37:40 +00:00
modularize Fixed some cases in the modularize assistant mode where header file names didn't translate to valid module names. 2016-03-21 23:05:14 +00:00
pp-trace Fix tests to not assume they know exactly what will be in Clang's predefines buffer. 2016-09-30 23:47:58 +00:00
.clang-format Add a .clang-format to avoid reflow of test RUN lines 2013-12-01 05:08:00 +00:00
CMakeLists.txt [clang-move] Make it support both relative and absolute file path arguments. 2016-10-04 09:05:31 +00:00
lit.cfg [find-all-symbols] Add a test to make sure merging actually works. 2016-05-31 12:12:19 +00:00
lit.site.cfg.in Replace hardcoded comment at 'lit.site.cfg.in' 2016-04-16 07:01:42 +00:00