Don't include <iostream> and "using" declarations in header files

<iostream> sucks in expensive initialization of the standard streams
and isn't appropriate in a header file. Use <istream> and <ostream>
instead.

using declarations should never appear at global scope in a header
file; source files get to decide what they want to use in their
namespace.
This commit is contained in:
timoore
2008-06-02 20:21:27 +00:00
parent 1a498348ee
commit d219c5c4c6
21 changed files with 151 additions and 196 deletions
+2 -4
View File
@@ -25,12 +25,10 @@ Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#endif
#define SampleHistogram_h 1
#include <iostream>
#include <ostream>
#include <fstream>
#include "SGSmplstat.hxx"
using namespace std;
extern const int SampleHistogramMinimum;
extern const int SampleHistogramMaximum;
@@ -56,7 +54,7 @@ public:
double bucketThreshold (int i);
int inBucket (int i);
void printBuckets (ostream &);
void printBuckets (std::ostream &);
};