4 ms·
Perhaps most importantly, a good CL implementation can help with debugging this, by keeping track of the original CL code that generated the intermediate code,
by martincmartin 5y ago
Perhaps most importantly, a good CL implementation can help with debugging this, by keeping track of the original CL code that generated the intermediate code, and pointing you to it. With the "use a program to generate C" approach, if there's some bug in the C code, the best the compiler or runtime can do is point you to the line of C code that's crashing. It's up to you to figure out where that came from.
This was a problem for early C++ compilers like Cfront that translated C++ into C: the error messages from the C compiler referenced the intermediate C, not the original C++.
- gmfawcett 5y agoHow old is the #line directive, I wonder? It's been a long time since Cfront. https://stackoverflow.com/questions/2216540/whats-the-meaning-of-line-in-c-language#2216564 https://stackoverflow.com/questions/2216540/whats-the-meanin...