Could you pass the compiler check if you write a code to pass-by-value but what you need to do is actually pass-by-reference? Or would it pass the check if you write a code to pass-by-reference but what you need to do is actually pass-by-value ?
your help please
C++ for beginners?
If I understand you correctly, you want to know if the compiler will allow you to write code that LOOKS correct but isn't. The compiler will not catch logic errors or errors in which you use the wrong method of variable passing. UNLESS, you reference that code from a subroutine and use the incorrect reference.
I am actually thinking of Visual Studio.net 2005 in the Visual Basic environment. If you use a different compiler... the results may be different.
In short, don't rely on the compiler to check your code for anything.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment