summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--config/src/vespa/config/print/fileconfigreader.h2
-rw-r--r--config/src/vespa/config/print/fileconfigreader.hpp3
-rw-r--r--document/src/vespa/document/select/node.h1
-rw-r--r--document/src/vespa/document/util/serializable.h56
-rw-r--r--frtstream/src/vespa/frtstream/frtstream.cpp1
-rw-r--r--frtstream/src/vespa/frtstream/frtstream.h2
-rw-r--r--memfilepersistence/src/vespa/memfilepersistence/common/freeptr.h42
-rw-r--r--staging_vespalib/src/vespa/vespalib/util/xmlserializable.h2
-rw-r--r--vespalib/src/vespa/vespalib/tensor/tensor_address.h2
-rw-r--r--vespalib/src/vespa/vespalib/util/printable.h2
10 files changed, 8 insertions, 105 deletions
diff --git a/config/src/vespa/config/print/fileconfigreader.h b/config/src/vespa/config/print/fileconfigreader.h
index 86ab43dcfc5..6b5f14b4318 100644
--- a/config/src/vespa/config/print/fileconfigreader.h
+++ b/config/src/vespa/config/print/fileconfigreader.h
@@ -1,8 +1,6 @@
// Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#pragma once
-#include <sstream>
-#include <fstream>
#include <vespa/vespalib/stllike/asciistream.h>
#include <vespa/config/common/misc.h>
#include <vespa/config/common/configvalue.h>
diff --git a/config/src/vespa/config/print/fileconfigreader.hpp b/config/src/vespa/config/print/fileconfigreader.hpp
index 4731b62047a..d5603794539 100644
--- a/config/src/vespa/config/print/fileconfigreader.hpp
+++ b/config/src/vespa/config/print/fileconfigreader.hpp
@@ -1,5 +1,8 @@
// Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
+#include <fstream>
+#include <sstream>
+
namespace config {
template <typename ConfigType>
diff --git a/document/src/vespa/document/select/node.h b/document/src/vespa/document/select/node.h
index 4a708022d8e..c56203da76c 100644
--- a/document/src/vespa/document/select/node.h
+++ b/document/src/vespa/document/select/node.h
@@ -12,7 +12,6 @@
#pragma once
-#include <iostream>
#include <string>
#include "resultlist.h"
#include "context.h"
diff --git a/document/src/vespa/document/util/serializable.h b/document/src/vespa/document/util/serializable.h
index d8f4d50c196..55b2f1ce629 100644
--- a/document/src/vespa/document/util/serializable.h
+++ b/document/src/vespa/document/util/serializable.h
@@ -12,7 +12,6 @@
#pragma once
-#include <iostream>
#include <map>
#include <vector>
@@ -42,8 +41,6 @@ public:
VESPA_DEFINE_EXCEPTION_SPINE(SerializeException)
};
-class XmlElement;
-
/**
* Base class for classes that can be converted into a bytestream,
* normally used later to create a similar instance.
@@ -180,58 +177,5 @@ public:
}
};
-/*
-
-class XmlElement
-{
-public:
- typedef std::map<std::string, std::string> AttributeMap;
- typedef std::vector<XmlElement> ElementList;
- XmlElement()
- : _valid(false),
- _name(),
- _value(),
- _attributes(),
- _elements()
- {
- }
- XmlElement(const std::string & n, const std::string & v)
- : _valid(true),
- _name(n),
- _value(v),
- _attributes(),
- _elements()
- {
- }
- const std::string & name() const { return _name; }
- const std::string & value() const { return _value; }
- const AttributeMap & attributes() const { return _attributes; }
- const ElementList & elements() const { return _elements; }
- bool valid() const { return _valid; }
- std::string attribute(const std::string & name) const;
- const XmlElement * element(const std::string & name) const;
-private:
- bool _valid;
- std::string _name;
- std::string _value;
- AttributeMap _attributes;
- ElementList _elements;
- friend std::ostream & operator << (std::ostream & os, const XmlElement & tag);
- friend std::istream & operator >> (std::istream & is, XmlElement & tag);
-};
-
-class XmlValue : public std::string
-{
-public:
- XmlValue() : std::string() { }
- XmlValue(const char * s) : std::string(s) { }
- XmlValue(const char * s, size_t sz) : std::string(s, sz) { }
- XmlValue(const std::string & s) : std::string(s) { }
-private:
- friend std::ostream & operator << (std::ostream & os, const XmlValue & tag);
- friend std::istream & operator >> (std::istream & is, XmlValue & tag);
-};
-*/
-
}
diff --git a/frtstream/src/vespa/frtstream/frtstream.cpp b/frtstream/src/vespa/frtstream/frtstream.cpp
index f4b1b9ddd7e..0e45f823f12 100644
--- a/frtstream/src/vespa/frtstream/frtstream.cpp
+++ b/frtstream/src/vespa/frtstream/frtstream.cpp
@@ -1,6 +1,7 @@
// Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#include <vespa/fastos/fastos.h>
#include <algorithm>
+#include <ostream>
#include <vespa/frtstream/frtstream.h>
diff --git a/frtstream/src/vespa/frtstream/frtstream.h b/frtstream/src/vespa/frtstream/frtstream.h
index 55ee2870f38..a640396b333 100644
--- a/frtstream/src/vespa/frtstream/frtstream.h
+++ b/frtstream/src/vespa/frtstream/frtstream.h
@@ -4,7 +4,7 @@
#include <string>
#include <memory>
#include <algorithm>
-#include <iostream>
+#include <iosfwd>
#include <iterator>
#include <vespa/fastos/fastos.h>
diff --git a/memfilepersistence/src/vespa/memfilepersistence/common/freeptr.h b/memfilepersistence/src/vespa/memfilepersistence/common/freeptr.h
deleted file mode 100644
index de807efed2a..00000000000
--- a/memfilepersistence/src/vespa/memfilepersistence/common/freeptr.h
+++ /dev/null
@@ -1,42 +0,0 @@
-// Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
-/**
- * @class storage::FreePtr
- * @ingroup slotfile
- *
- * @brief Simple pointer wrapper that free() its content when deleted.
- *
- * Utility used to hold memory allocated with malloc directly.
- */
-
-#pragma once
-
-#include <iostream>
-#include <sstream>
-
-namespace storage {
-
-template<typename T>
-class FreePtr {
- T* _ptr;
-
-public:
- FreePtr(T* ptr = 0) : _ptr(ptr) {}
- ~FreePtr() { free(); }
-
- FreePtr(FreePtr& ptr) : _ptr(ptr._ptr) { ptr._ptr = 0; }
- FreePtr& operator=(FreePtr& ptr) { swap(ptr); ptr.free(); return *this; }
-
- void reset(T* ptr = 0) { free(); _ptr = ptr; }
- void swap(FreePtr<T>& other)
- { T* tmp = _ptr; _ptr = other._ptr; other._ptr = tmp; }
- T* get() { return _ptr; }
- const T* get() const { return _ptr; }
- T* operator->() { return _ptr; }
- const T* operator->() const { return _ptr; }
- T& operator*() { assert(_ptr != 0); return *_ptr; }
- const T& operator*() const { assert(_ptr != 0); return *_ptr; }
- void free() { if (_ptr != 0) { ::free(_ptr); _ptr = 0; } }
-};
-
-} // storage
-
diff --git a/staging_vespalib/src/vespa/vespalib/util/xmlserializable.h b/staging_vespalib/src/vespa/vespalib/util/xmlserializable.h
index 83162024580..f79af671b7d 100644
--- a/staging_vespalib/src/vespa/vespalib/util/xmlserializable.h
+++ b/staging_vespalib/src/vespa/vespalib/util/xmlserializable.h
@@ -29,7 +29,7 @@
#pragma once
-#include <iostream>
+#include <ostream>
#include <list>
#include <memory>
#include <sstream>
diff --git a/vespalib/src/vespa/vespalib/tensor/tensor_address.h b/vespalib/src/vespa/vespalib/tensor/tensor_address.h
index 42dceb65ae2..07f6d5b88ea 100644
--- a/vespalib/src/vespa/vespalib/tensor/tensor_address.h
+++ b/vespalib/src/vespa/vespalib/tensor/tensor_address.h
@@ -4,7 +4,7 @@
#include <vespa/vespalib/stllike/hash_fun.h>
#include <vespa/vespalib/stllike/string.h>
-#include <iostream>
+#include <iosfwd>
#include <map>
#include <vector>
diff --git a/vespalib/src/vespa/vespalib/util/printable.h b/vespalib/src/vespa/vespalib/util/printable.h
index 7ce1ee073ed..d3042a69bef 100644
--- a/vespalib/src/vespa/vespalib/util/printable.h
+++ b/vespalib/src/vespa/vespalib/util/printable.h
@@ -32,7 +32,7 @@
#include <string>
#include <vespa/vespalib/stllike/asciistream.h>
-#include <iostream>
+#include <iosfwd>
namespace vespalib
{