crosire / blink

A tool which allows you to edit source code of any MSVC C++ project live at runtime
BSD 2-Clause "Simplified" License
1.09k stars 81 forks source link

compiler error messages not displayed #21

Closed Trass3r closed 5 years ago

Trass3r commented 5 years ago

When #20 occurred I didn't get any error messages, even when commenting out the "Only print error information" if @ blink.cpp:283

Maybe it should keep stderr separate from stdout and always print it instead of merging and parsing? That might also fix another usability issue: if you compile without /ZI and blink is run from a normal cmd (not VS dev) it can't find cl.exe but no error message is displayed ("cl.exe is not recognized...")

crosire commented 5 years ago

I'm not able to reproduce that. If I run a small test app with PCH I get this output in the blink console:

...
Starting file system watcher for 'c:\projects\blink-test\source' ...
Detected modification to: c:\projects\blink-test\source\main.cpp
c:\projects\blink-test\source\main.cpp(1): error C2855: command-line option '/Z7' inconsistent with precompiled header
Finished compiling "c:\projects\blink-test\source\main.temp.obj" with code 2.

cl.exe also doesn't print errors to stderr for me, they all go to stdout (verified via cl.exe ... 2> errors.log). So it doesn't look like printing stderr would help here.

Trass3r commented 5 years ago

Detected modification to: c:\projects\blink-test\source\main.cpp c:\projects\blink-test\source\main.cpp(1): error C2855: command-line option '/Z7' inconsistent with precompiled header

That's odd. I tried again, it worked the first time but then not anymore, I only get:

Detected modification to: test.cpp
test.cpp

compile complete 2

cl.exe also doesn't print errors to stderr for me

Then it must be gcc doing that.