Visual Studio 2008 compiles anything in the C file?

I noticed today that the source code file in the project is being compiled, even if it has garbage at the top. It makes me want to know that the compiler will pass nothing wrong. The following is not generated Code example of any error message:

what kind of weird behaviour is this???

#include "stdafx.h"< br />
// what is up?

int foo(int bar)
{
bla bla bla?????
return bar ;
}

and more junk???

What does the compiler do in the world to allow the code to be compiled without giving any error messages? I am using Visual Studio 2008, which is unmanaged C code. The foo function is not actually generated in the object file, so it cannot be used, but why is there no error?

#include “stdafx.h” The part before the line is actually interpretable (assuming the file Actually compiled): If precompiled header files are enabled (by default), everything before and after the line is ignored. For a short summary, see Wikipedia on Precompiled Headers.

However, if the following syntax error code does not produce an error, then it is very likely that your file has not been compiled at all.

I noticed today that the source code file in the project is working Compile, even if it has garbage on the top. It makes me wonder if the compiler will pass through without errors. The following is a code example that does not generate any error messages:

< pre>what kind of weird behaviour is this???

#include “stdafx.h”

// what is up?

int foo(int bar)
{
bla bla bla?????
return bar;
}

and more junk???

What does the compiler do in the world to allow the code to be compiled without giving any error messages? I am using Visual Studio 2008, which is unmanaged C code. The foo function is not actually generated in the object file, so it cannot be used, but why is there no error?

The part before the #include “stdafx.h” line is actually interpretable (assuming the file is actually compiled): if precompiled header files are enabled (By default), everything before and after the line is ignored. For a short summary, see Wikipedia on Precompiled Headers.

However, if you include the following syntax error code, no error is generated , Then it is very likely that your file is not compiled at all.

WordPress database error: [Table 'yf99682.wp_s6mz6tyggq_comments' doesn't exist]
SELECT SQL_CALC_FOUND_ROWS wp_s6mz6tyggq_comments.comment_ID FROM wp_s6mz6tyggq_comments WHERE ( comment_approved = '1' ) AND comment_post_ID = 1914 ORDER BY wp_s6mz6tyggq_comments.comment_date_gmt ASC, wp_s6mz6tyggq_comments.comment_ID ASC

Leave a Comment

Your email address will not be published.