开发者

I'm changing my code but the compiled program isn't being affected

I'm doing a project in C++ with Codeblocks. I closed out of Codebl开发者_StackOverflow中文版ocks and re-opened it, and now when I edit, save and compile the code the .exe doesn't change at all. The log says "Checking for existence: C:\Users\AJ\Code\sndbrd\bin\Debug\sndbrd.exe Executing: "C:\Program Files\CodeBlocks/cb_console_runner.exe" "C:\Users\AJ\Code\sndbrd\bin\Debug\sndbrd.exe" (in C:\Users\AJ\Code\sndbrd\.)" Also I have two executables, main.exe, located where main.cpp is, and sndbrd in the bin/debug folder.


The compiler uses timestamp of obj executable/obj-files/cpp-header files to determine if compilation/linking is necessary. If for whatever reason your executable/obj-files timestamps > cpp-header files, (ie. cpp-header is newer) then compiler wont think compilation/linking is necessary.

Simple solution is to simply delete all the obj/exe files and then recompile.

It should work.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜