Date/Time: Thu, 30 Nov 2023 01:49:53 +0000
fatal error: defs.cpp: No such file or directory
View Count: 135
|User286186 - Posts: 20|
Hello, Since I am trying to modularize my code, I want to #include a "defs.cpp" file with some functions in order to use them in my main "modularCode.cpp" ACS.
I compile "defs.cpp" file without any problem.
The problem is triggered when a fatal compilation error arise as I try to compile the main "modularCode.cpp" file that #include "defs.cpp".
modularCode.cpp:3:10: fatal error: defs.cpp: No such file or directory
3 | #include "defs.cpp"
Both files are in the correct folder (ACS_Source) as any other file which is included in my "modularCode.cpp" (for instance, no problem including sierrachart.h or scstructures.h).
Could you please help me ?
Thank you !
|User431178 - Posts: 338|
Create a header file, defs.h, that has the declarations for the functions in defs.cpp.
Then #include "defs.h" (not #include "defs.cpp").
To post a message in this thread, you need to log in with your Sierra Chart account: