Home > DeveloperSection > Interviews > What You Should Include in a Header File ?

Posted on    March-28-2011 8:47 AM

 Visual C++ Visual C++ 
 1 Answer(s)
  1227  View(s)
Rate this:

Dependra Pathak
Dependra Pathak

Total Post:77

Posted on    March-28-2011 12:00 AM

A header file should begin and end with #include guards to guarantee that it?s not #included more than once during the same compilation session. A typical #include guard looks as follows:
// from stdlib.h
#ifndef STDLIB_INCLUDED // included for the first time?

Don't want to miss updates? Please click the below button!

Follow MindStick