control-flag icon indicating copy to clipboard operation
control-flag copied to clipboard

[FEATURE]Support for the Cpp programming language

Open jiangwei007 opened this issue 3 years ago • 2 comments

When I use ControlFlag to scan Unreal Engine, ControlFlag scans only *.h && *.c c-style files and does not scan any *.cpp files

Expect ControlFlag to support C Plus Plus Mine and scan

Or, what can I do to support CPP

jiangwei007 avatar Nov 03 '21 12:11 jiangwei007

Hi @jiangwei007 - right now the parser is setup to only scan .h and .c files, however, you can modify that to include .cpp files. @nhasabni - can you point @jiangwei007 to the modification point in the script?

The reason why we don't add .cpp files by default is because we haven't yet added C++-specific learning to the system. However, you may still be able to find issues in your code in C++ due to C++ being somewhat of a superset of C. That said, once we've added proper C++ learning, we anticipate the results may be much better.

Best, The ControlFlag Team

jgottschlich avatar Nov 03 '21 16:11 jgottschlich

hi @jiangwei007,

Thanks for interest in ControlFlag. Place to add those extensions would be in the scanning and mining scripts.

That being said, we are working on completing C++ support, by generating C++-specific training data. We plan to upstream the changes soon.

nhasabni avatar Nov 03 '21 17:11 nhasabni