After making the change for the speedup(parser only on demand), CDTParser should have been modified to use the DOMCompilerSuffixes class methods checkC/checkCPP to determine whether or not a file is a c or c++ type file.
Fixed in HEAD.