C++ and C Source Files in the Same Environment

Question:
I have .c and .cpp files that I want to test in the same environment. How can I configure VectorCAST to compile them properly?
Answer:

To test a combination of .c and .cpp files in the same environment, choose the C++ version of the compiler template that is applicable to your compiler in the Tools | Options dialog, C/C++ tab. Selecting a C++ template will populate the Preprocessor/Compiler sub-tab with the correct options for compiling .cpp files, and will populate the Mixed C/C++ sub-tab with the correct options for compiling .c files.
 


 

Normally, you will not need to make changes to these commands. If you do make changes to the compile command, however, you should make the same changes to the command on the Mixed C/C++ tab.
 



Article ID: 1479
Last updated: 2019-10-29
Revision: 3
VectorCAST -> C++ Unit Testing -> C++ and C Source Files in the Same Environment
https://kb.vector.com/entry/1479/