CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 6 of 6
  1. #1
    Join Date
    Mar 2006
    Posts
    6

    iostream.h missing file or directory

    im coding c++ in linux (ubuntu) and when i compiled an error comes up that this file is missing. i don't remember doing anything drastic as to lose files/libraries. what could be the problem? thanks!

  2. #2
    Join Date
    Dec 2004
    Location
    Poland
    Posts
    1,165

    Re: iostream.h missing file or directory

    iostream.h is nonstandard header file and it might be not available with your compiler. Try iostream instead.

    Regards,
    Hob
    B+!
    'There is no cat' - A. Einstein

    Use [code] [/code] tags!

    Did YOU share your photo with us at CG Members photo gallery ?

  3. #3
    Join Date
    Mar 2006
    Posts
    6

    Re: iostream.h missing file or directory

    i've used this header before and now it can't be found...
    so, do you think it's more likely that i've tampered with my current library?

  4. #4
    Join Date
    Dec 2004
    Location
    Poland
    Posts
    1,165

    Re: iostream.h missing file or directory

    If you are using quite new version of compiler (and I think that you do), do not even bother including iostream.h. This file is obsolete and put into libraries for backward compatibility only. The same functionality, but conforming to curent standards, is placed inside of iostream, so just put
    Code:
    #include <iostream>
    line in your app.

    Maybe before you were using backward-compatible libraries which included iostream.h, and now switched to more modern one.

    Hob
    B+!
    'There is no cat' - A. Einstein

    Use &#91;code] [/code] tags!

    Did YOU share your photo with us at CG Members photo gallery ?

  5. #5
    Join Date
    Apr 1999
    Posts
    27,449

    Re: iostream.h missing file or directory

    Quote Originally Posted by beej
    i've used this header before
    You shouldn't have used it to begin with
    and now it can't be found...
    And it isn't required to be there.
    so, do you think it's more likely that i've tampered with my current library?
    No. The <iostream.h> never has been an official standard header. No compiler is required to have it or support it.

    The correct standard C++ header, as pointed out by Hobson, is <iostream>. Even if your compiler has <iostream.h>, you should still use <iostream>.

    Regards,

    Paul McKenzie

  6. #6
    Join Date
    Feb 2005
    Location
    Normandy in France
    Posts
    4,590

    Re: iostream.h missing file or directory

    Read the FAQ.
    And this Herb Sutter's article if you need to convert a whole project.
    "inherit to be reused by code that uses the base class, not to reuse base class code", Sutter and Alexandrescu, C++ Coding Standards.
    Club of lovers of the C++ typecasts cute syntax: Only recorded member.

    Out of memory happens! Handle it properly!
    Say no to g_new()!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured