Martin Hvidberg wrote:
Dear list
I have found a declaration like this:
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <time.h>
#include <math.h>
#include "ectemp.h"
The last line differ from the rest?
I guess it's about where to look for the .h file(s), but can somebody
please make the difference clear...
Two answers to this.
Answer 1 is informal. Basically, on your implementation (assuming
you're running a typical desktop system) <header> probably means
"look in the usual places where you'd expect to find system headers
and third-party lib headers", and "header" probably means "look in
the current directory first; if not there, search the usual places".
Answer 2 is far less friendly, but rather more accurate!
My 1989 draft says, in 3.1.7:
"The sequences in both forms of header names are mapped in an
implementation-defined manner to headers or external source file names
as specified in $3.8.2."
And 3.8.2 says:
"A preprocessing directive of the form
# include <h-char-sequence> new-line
searches a sequence of implementation-defined places for a header
identified uniquely by the specified sequence between the < and >
delimiters, and causes the replacement of that directive by the entire
contents of the header. How the places are specified or the header
identified is implementation-defined.
A preprocessing directive of the form
# include "q-char-sequence" new-line
causes the replacement of that directive by the entire contents of the
source file identified by the specified sequence between the
delimiters. The named source file is searched for in an
implementation-defined manner. If this search is not supported, or if
the search fails, the directive is reprocessed as if it read
# include <h-char-sequence> new-line
with the identical contained sequence (including > characters, if any)
from the original directive."