iostream.h是非标准头文件,iostream是标准头文件形式。iostream.h时代没有名词空间,即所有库函数包括头文
件iostream.h都声明在全局域。为了体现结构层次,c++标准委员会引入了名词空间这一概念,并把所有库函数声
明由全局域改到了名词空间std。故而,
目前这两种头文件等价:
#include<iostream.h>

#include <iostream>
using namespace std;
(因为iostream声明在std中,故而要加上这句,除非你不用库函数,否则错误); 很多编译器都同时支持这两种头文件形式,更好的当然是标准头文件。至于为什么不废除非标准头文件,大概
是为了兼容以前的代码吧。 还有一点在标准c++中,所有库函数都没有.h后缀了,如果是c语言的库函数,则去掉后缀,并在开头加上一个c
(如,c++的string.h变为string,c语言的stdio.h,变为cstdio,c语言的string.h变为cstring等等)。

reference:

http://blog.chinaunix.net/uid-26696487-id-3151002.html

[转]fatal error: iostream.h: No such file or directory的更多相关文章

  1. plugins/python/uwsgi_python.h:2:20: fatal error: Python.h: No such file or directory

    装一台新服务器环境的时候,装uwsgi报错: plugins/python/uwsgi_python.h:2:20: fatal error: Python.h: No such file or di ...

  2. [lua]luasocket.c:20:17: fatal error: lua.h: No such file or directory

    安装luasocket的时候出现了如下的错误 问题 $ tar xzf luasocket-2.0.2.tar.gz $ cd luasocket-2.0.2 $ $ make cd src; mak ...

  3. Solve fatal error: helper_math.h: No such file or directory

    When the 'fatal error: helper_math.h: No such file or directory' occurs, it means the 'helper_math.h ...

  4. qingstor python-sdk 安装错误 src/MD2.c:31:20: fatal error: Python.h: No such file or directory

    ubuntu安装python qingstor-sdk, src/MD2.c:31:20: fatal error: Python.h: No such file or directory compi ...

  5. Ubuntu下 fatal error: Python.h: No such file or directory 解决方法

    参考: fatal error: Python.h: No such file or directory Ubuntu下 fatal error: Python.h: No such file or ...

  6. tesseract编译错误:fatal error: allheaders.h: No such file or directory

    错误描述: globaloc.cpp::: fatal error: allheaders.h: No such file or directory #include "allheaders ...

  7. 解决 Boost安装:fatal error: bzlib.h: No such file or directory 问题

    参考: How to install all the boost development libraries? 解决 Boost安装:fatal error: bzlib.h: No such fil ...

  8. caffe编译问题-src/caffe/net.cpp:8:18: fatal error: hdf5.h: No such file or directory compilation terminated.

    错误描述 src/caffe/net.:: fatal error: hdf5.h: No such : recipe 操作过程 step1: 在Makefile.config文件更改INCLUDE_ ...

  9. /usr/include/glib-2.0/glib/gtypes.h:34:24: fatal error: glibconfig.h: No such file or directory

    cc -DDEBUG -mtune=core2 -O2 \ -onvideo nvideo.c \ -I/usr/include/atk-1.0 \ -I/usr/include/cairo \ -I ...

随机推荐

  1. ACM ICPC Team

    Link: https://www.hackerrank.com/challenges/acm-icpc-team/submissions/code/11617807 def count_max_to ...

  2. 拼接xml时出现内存溢出解决办法

    /// designed by Alex /// 解决内存溢出问题,不可使用迭代器和foreach /// 循环遍历List, 别生成xml,一边释放 /// 反向遍历,相当于出栈,避免索引顺序乱的问 ...

  3. 云风:我所偏爱的C语言面向对象编程范式

    面向对象编程不是银弹.大部分场合,我对面向对象的使用非常谨慎,能不用则不用.相关的讨论就不展开了. 但是,某些场合下,采用面向对象的确是比较好的方案.比如 UI 框架,又比如 3d 渲染引擎中的场景管 ...

  4. UVa133.The Dole Queue

    题目链接:http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&page=show_problem& ...

  5. 初探JS正则表达式

    1.概述     正则表达式是一个描述字符模式的对象.Javascript的正则表达式语法的是Perl5的正则表达式的子集.JS正则表达式有两种使用方式,文本模式和RegExp对象模式,实例如下: v ...

  6. c、c++知识点

    一. (1)在linux下类似uint8_t这样的文件定义在头文件<stdint.h>里面   (2)截取了stdint.h头文件里的一些常用部分 二.c++中c_str()用法 函数返回 ...

  7. hdu 1159 Common Subsequence(LCS最长公共子序列)

    Common Subsequence Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Other ...

  8. Android-JNI编程-图文解析

    要想阅读并调试下文源码,首先要确保你的NDK环境是ok的:        编译环境:win7+Eclipse+ADT+SDK+NDK:基本用最新的就ok.        说明下,下文代码就是一个简单的 ...

  9. iOS7 StatusBar 使用小结

    1. 样式 2. 显示和隐藏 3. 动画效果 4. 默认无StatusBar 其他 iOS7 中的StatusBar和之前版本的相比发生了很大变化,在iOS7下对statusbar的使用需要全新的方法 ...

  10. [汇编学习笔记][第十章 CALL和RET指令]

    第十章 CALL和RET指令 call和ret指令都是转移指令,它们都修改CS和IP.经常被共同用于实现子程序的设计.这一章,我们讲解call和ret指令的原理 10.1 ret和retf ret指令 ...