Dan Stromberg <[EMAIL PROTECTED]> writes:

> esmf04m-strombrg> cat t.C
>
> main()
>         {
>         using ::malloc;
>         }

This is not a well-formed C++ program.

In your original message, you said:
> I keep getting this weird "malloc not declared" errors when cstdlib is
> included. 

Fixing the test above:

$ cat t.C
#include <cstdlib>
int main()
{
    using ::malloc;
}

makes it compile just fine.

> t.C: In function `int main()':
> t.C:4: error: `malloc' not declared
> make: *** [t] Error 1

Naturally: you didn't #include appropriate header, hence the error.

Cheers,
-- 
In order to understand recursion you must first understand recursion.
Remove /-nsp/ for email.
_______________________________________________
Help-gplusplus mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/help-gplusplus

Reply via email to