aboutsummaryrefslogtreecommitdiffstats
path: root/vespalib
diff options
context:
space:
mode:
authorHenning Baldersheim <balder@yahoo-inc.com>2017-08-18 12:04:45 +0200
committerHenning Baldersheim <balder@yahoo-inc.com>2017-08-18 12:04:45 +0200
commit64809ac8367bb4c059f55a8595f47a323237b238 (patch)
tree62af23907c274c398b231340c006a76700c8f90c /vespalib
parent7bbbf406f3cd920222aba9039c6a460370a4ab14 (diff)
Remove more clutter in fastos/types.h
Diffstat (limited to 'vespalib')
-rw-r--r--vespalib/src/tests/alloc/allocate_and_core.cpp2
-rw-r--r--vespalib/src/tests/exception_classes/mmap.cpp2
-rw-r--r--vespalib/src/tests/zcurve/zcurve_test.cpp40
-rw-r--r--vespalib/src/vespa/vespalib/data/slime/inspector.cpp2
-rw-r--r--vespalib/src/vespa/vespalib/data/slime/strfmt.cpp2
-rw-r--r--vespalib/src/vespa/vespalib/net/socket_handle.cpp2
-rw-r--r--vespalib/src/vespa/vespalib/test/socket_options_verifier.h8
-rw-r--r--vespalib/src/vespa/vespalib/util/arrayqueue.hpp2
-rw-r--r--vespalib/src/vespa/vespalib/util/backtrace.cpp2
-rw-r--r--vespalib/src/vespa/vespalib/util/generationhandler.h2
-rw-r--r--vespalib/src/vespa/vespalib/util/linkedptr.h2
-rw-r--r--vespalib/src/vespa/vespalib/util/signalhandler.h2
-rw-r--r--vespalib/src/vespa/vespalib/util/valgrind.cpp2
13 files changed, 32 insertions, 38 deletions
diff --git a/vespalib/src/tests/alloc/allocate_and_core.cpp b/vespalib/src/tests/alloc/allocate_and_core.cpp
index faf44aa2669..7b72f35ac0e 100644
--- a/vespalib/src/tests/alloc/allocate_and_core.cpp
+++ b/vespalib/src/tests/alloc/allocate_and_core.cpp
@@ -1,7 +1,7 @@
// Copyright 2017 Yahoo Holdings. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#include <vespa/vespalib/util/alloc.h>
#include <string.h>
-#include <assert.h>
+#include <cassert>
using namespace vespalib::alloc;
diff --git a/vespalib/src/tests/exception_classes/mmap.cpp b/vespalib/src/tests/exception_classes/mmap.cpp
index 3ba286f2a35..2d4c4796473 100644
--- a/vespalib/src/tests/exception_classes/mmap.cpp
+++ b/vespalib/src/tests/exception_classes/mmap.cpp
@@ -1,7 +1,7 @@
// Copyright 2017 Yahoo Holdings. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#include <vespa/vespalib/util/alloc.h>
#include <vector>
-#include <assert.h>
+#include <cassert>
#include <string.h>
#include <sys/resource.h>
diff --git a/vespalib/src/tests/zcurve/zcurve_test.cpp b/vespalib/src/tests/zcurve/zcurve_test.cpp
index 89bc3fed051..67f6a622ff0 100644
--- a/vespalib/src/tests/zcurve/zcurve_test.cpp
+++ b/vespalib/src/tests/zcurve/zcurve_test.cpp
@@ -1,12 +1,14 @@
// Copyright 2017 Yahoo Holdings. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
-#include <vespa/log/log.h>
-LOG_SETUP("zcurve_test");
#include <vespa/vespalib/testkit/testapp.h>
#include <vespa/vespalib/geo/zcurve.h>
#include <algorithm>
#include <limits>
#include <map>
+#include <sys/time.h>
+
+#include <vespa/log/log.h>
+LOG_SETUP("zcurve_test");
namespace vespalib {
@@ -20,34 +22,26 @@ public:
{
}
- void
- testEncoding(void);
+ void testEncoding();
- void
- testDecoding(void);
+ void testDecoding();
- double
- ftime(void);
+ double ftime();
- static inline int64_t
- encodexy3(int32_t x, int32_t y);
+ static inline int64_t encodexy3(int32_t x, int32_t y);
#define BMLIMIT 0x1000000
template <bool decode>
- int64_t
- bm(void);
+ int64_t bm();
template <bool decode>
- int64_t
- bm2(void);
+ int64_t bm2();
template <bool decode>
- int64_t
- bm3(void);
+ int64_t bm3();
- int64_t
- bmcheck();
+ int64_t bmcheck();
int Main() override;
};
@@ -140,7 +134,7 @@ ZCurveTest::testDecoding(void)
double
-ZCurveTest::ftime(void)
+ZCurveTest::ftime()
{
struct timeval tv;
gettimeofday(&tv, NULL);
@@ -183,7 +177,7 @@ ZCurveTest::encodexy3(int32_t x, int32_t y)
template <bool decode>
int64_t
-ZCurveTest::bm(void)
+ZCurveTest::bm()
{
int64_t res = 0;
double before = ftime();
@@ -265,7 +259,7 @@ ZCurveTest::bm2(void)
template <bool decode>
int64_t
-ZCurveTest::bm3(void)
+ZCurveTest::bm3()
{
int64_t res = 0;
double before = ftime();
@@ -305,7 +299,7 @@ ZCurveTest::bm3(void)
int64_t
-ZCurveTest::bmcheck(void)
+ZCurveTest::bmcheck()
{
int64_t res = 0;
double before = ftime();
@@ -348,7 +342,7 @@ ZCurveTest::bmcheck(void)
int
-ZCurveTest::Main(void)
+ZCurveTest::Main()
{
TEST_INIT("zcurve_test");
diff --git a/vespalib/src/vespa/vespalib/data/slime/inspector.cpp b/vespalib/src/vespa/vespalib/data/slime/inspector.cpp
index 46847c20754..1f5631accc6 100644
--- a/vespalib/src/vespa/vespalib/data/slime/inspector.cpp
+++ b/vespalib/src/vespa/vespalib/data/slime/inspector.cpp
@@ -3,7 +3,7 @@
#include "inspector.h"
#include "object_traverser.h"
#include "array_traverser.h"
-#include <assert.h>
+#include <cassert>
namespace vespalib {
namespace slime {
diff --git a/vespalib/src/vespa/vespalib/data/slime/strfmt.cpp b/vespalib/src/vespa/vespalib/data/slime/strfmt.cpp
index 7b16382dde3..487badfabf8 100644
--- a/vespalib/src/vespa/vespalib/data/slime/strfmt.cpp
+++ b/vespalib/src/vespa/vespalib/data/slime/strfmt.cpp
@@ -3,7 +3,7 @@
#include "strfmt.h"
#include <stdarg.h>
#include <stdio.h>
-#include <assert.h>
+#include <cassert>
namespace vespalib {
namespace slime {
diff --git a/vespalib/src/vespa/vespalib/net/socket_handle.cpp b/vespalib/src/vespa/vespalib/net/socket_handle.cpp
index 5e1e8f0155b..36eae46031f 100644
--- a/vespalib/src/vespa/vespalib/net/socket_handle.cpp
+++ b/vespalib/src/vespa/vespalib/net/socket_handle.cpp
@@ -3,7 +3,7 @@
#include "socket_handle.h"
#include <sys/socket.h>
#include <errno.h>
-#include <assert.h>
+#include <cassert>
namespace vespalib {
diff --git a/vespalib/src/vespa/vespalib/test/socket_options_verifier.h b/vespalib/src/vespa/vespalib/test/socket_options_verifier.h
index 2be96b861af..72694f643e2 100644
--- a/vespalib/src/vespa/vespalib/test/socket_options_verifier.h
+++ b/vespalib/src/vespa/vespalib/test/socket_options_verifier.h
@@ -6,9 +6,10 @@
#include <fcntl.h>
#include <unistd.h>
#include <netinet/tcp.h>
+#include <sys/socket.h>
+#include <netinet/in.h>
-namespace vespalib {
-namespace test {
+namespace vespalib::test {
namespace {
@@ -59,5 +60,4 @@ struct SocketOptionsVerifier {
}
};
-} // namespace vespalib::test
-} // namespace vespalib
+}
diff --git a/vespalib/src/vespa/vespalib/util/arrayqueue.hpp b/vespalib/src/vespa/vespalib/util/arrayqueue.hpp
index 85f4afabf9f..6c26fd3a0c4 100644
--- a/vespalib/src/vespa/vespalib/util/arrayqueue.hpp
+++ b/vespalib/src/vespa/vespalib/util/arrayqueue.hpp
@@ -5,7 +5,7 @@
#include <stdint.h>
#include <stdlib.h>
-#include <assert.h>
+#include <cassert>
#include <algorithm>
#include "traits.h"
diff --git a/vespalib/src/vespa/vespalib/util/backtrace.cpp b/vespalib/src/vespa/vespalib/util/backtrace.cpp
index 33c3cebe8a8..ee7f39597a6 100644
--- a/vespalib/src/vespa/vespalib/util/backtrace.cpp
+++ b/vespalib/src/vespa/vespalib/util/backtrace.cpp
@@ -7,7 +7,7 @@
#include <vespa/vespalib/stllike/asciistream.h>
#include <vespa/fastos/backtrace.h>
#include <execinfo.h>
-#include <signal.h>
+#include <csignal>
namespace {
diff --git a/vespalib/src/vespa/vespalib/util/generationhandler.h b/vespalib/src/vespa/vespalib/util/generationhandler.h
index fbc6f1ae78a..d8af7f39c3e 100644
--- a/vespalib/src/vespa/vespalib/util/generationhandler.h
+++ b/vespalib/src/vespa/vespalib/util/generationhandler.h
@@ -4,7 +4,7 @@
#include <stdint.h>
#include <atomic>
-#include <assert.h>
+#include <cassert>
namespace vespalib {
diff --git a/vespalib/src/vespa/vespalib/util/linkedptr.h b/vespalib/src/vespa/vespalib/util/linkedptr.h
index ca464f48cbb..517208b9ef9 100644
--- a/vespalib/src/vespa/vespalib/util/linkedptr.h
+++ b/vespalib/src/vespa/vespalib/util/linkedptr.h
@@ -5,7 +5,7 @@
#include <algorithm>
#include <memory>
-#include <assert.h>
+#include <cassert>
namespace vespalib {
diff --git a/vespalib/src/vespa/vespalib/util/signalhandler.h b/vespalib/src/vespa/vespalib/util/signalhandler.h
index 7db23f72570..6b233b2e690 100644
--- a/vespalib/src/vespa/vespalib/util/signalhandler.h
+++ b/vespalib/src/vespa/vespalib/util/signalhandler.h
@@ -1,7 +1,7 @@
// Copyright 2017 Yahoo Holdings. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#pragma once
-#include <signal.h>
+#include <csignal>
#include <vector>
namespace vespalib {
diff --git a/vespalib/src/vespa/vespalib/util/valgrind.cpp b/vespalib/src/vespa/vespalib/util/valgrind.cpp
index d84855e8005..cbb6cc808fc 100644
--- a/vespalib/src/vespa/vespalib/util/valgrind.cpp
+++ b/vespalib/src/vespa/vespalib/util/valgrind.cpp
@@ -1,7 +1,7 @@
// Copyright 2017 Yahoo Holdings. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#include <vespa/vespalib/util/valgrind.h>
-#include <assert.h>
+#include <cassert>
#include <fcntl.h>
#include <unistd.h>