qn regarding new library

in the tutorial section, it says I need to include the new library like so:
#include<new> in order to dynamically allocate memory using the new keyword but why is it that I can compile and use my programs without explicitly including the library and some c++ books don't indicate the need to include that library as well?

if it is automatically linked, is it better to explicitly state #include<new>?
Because It search from default libraray directory(ie:C:\Program Files\Microsoft Visual Studio 8\VC\lib). So you don't explicitly include lib.
but is it better to explicitly do so?
new is a keyword. You don't need to include anything to use it, since it's part of the language.
<new>, from what I can read in the header, adds exception handling to new.
Is that MS-specific or is it a standard header? Just for my edification...
Nope. It's standard. I found it in "include/c++/3.4.5/new" in MinGW.
It's odd that I can't find it in the reference, though.
Topic archived. No new replies allowed.