Delete root header file typedef.h.
Usage replaced with stdint.h, rtc_base/system/arch.h and
rtc_base/system/unused.h, as appropriate.
Bug: webrtc:6854
Change-Id: I97225465d14b969903d92979e2df3c3c05d35f18
Reviewed-on: https://webrtc-review.googlesource.com/90249
Reviewed-by: Niklas Enbom <niklas.enbom@webrtc.org>
Reviewed-by: Fredrik Solenberg <solenberg@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24100}
diff --git a/rtc_base/BUILD.gn b/rtc_base/BUILD.gn
index 7f9d834..f4b89dd 100644
--- a/rtc_base/BUILD.gn
+++ b/rtc_base/BUILD.gn
@@ -109,6 +109,9 @@
"stringize_macros.h",
"thread_annotations.h",
]
+ deps = [
+ "system:arch",
+ ]
}
rtc_source_set("platform_thread_types") {
@@ -150,7 +153,7 @@
":checks",
":macromagic",
":platform_thread_types",
- "..:typedefs",
+ "system:unused",
]
}
@@ -174,7 +177,6 @@
":rtc_event",
":thread_checker",
":timeutils",
- "..:typedefs",
]
}
@@ -239,7 +241,6 @@
":criticalsection",
":macromagic",
":platform_thread_types",
- "..:typedefs",
]
}
@@ -256,7 +257,6 @@
]
deps = [
":safe_compare",
- "..:typedefs",
"system:inline",
]
}
@@ -387,8 +387,8 @@
":thread_checker",
":timeutils",
":type_traits",
- "../:typedefs",
"system:arch",
+ "system:unused",
"third_party/base64",
]
@@ -557,6 +557,7 @@
":rtc_task_queue_api",
":safe_conversions",
":timeutils",
+ "system:unused",
]
if (rtc_build_libevent) {
deps += [ "//base/third_party/libevent" ]
diff --git a/rtc_base/criticalsection.cc b/rtc_base/criticalsection.cc
index c786a40..d8a5b48 100644
--- a/rtc_base/criticalsection.cc
+++ b/rtc_base/criticalsection.cc
@@ -13,6 +13,7 @@
#include "rtc_base/atomicops.h"
#include "rtc_base/checks.h"
#include "rtc_base/platform_thread_types.h"
+#include "rtc_base/system/unused.h"
// TODO(tommi): Split this file up to per-platform implementation files.
diff --git a/rtc_base/criticalsection.h b/rtc_base/criticalsection.h
index ce6fca1..f25e7d0 100644
--- a/rtc_base/criticalsection.h
+++ b/rtc_base/criticalsection.h
@@ -15,7 +15,6 @@
#include "rtc_base/constructormagic.h"
#include "rtc_base/platform_thread_types.h"
#include "rtc_base/thread_annotations.h"
-#include "typedefs.h" // NOLINT(build/include)
#if defined(WEBRTC_WIN)
// clang-format off
diff --git a/rtc_base/format_macros.h b/rtc_base/format_macros.h
index 48127e1..7252f2e 100644
--- a/rtc_base/format_macros.h
+++ b/rtc_base/format_macros.h
@@ -37,6 +37,8 @@
#include <inttypes.h>
+#include "rtc_base/system/arch.h"
+
#if !defined(PRIuS)
#define PRIuS "zu"
#endif
diff --git a/rtc_base/memory/BUILD.gn b/rtc_base/memory/BUILD.gn
index e24b8ce..05fd7ab 100644
--- a/rtc_base/memory/BUILD.gn
+++ b/rtc_base/memory/BUILD.gn
@@ -27,9 +27,7 @@
"aligned_malloc.cc",
"aligned_malloc.h",
]
- deps = [
- "../..:typedefs",
- ]
+ deps = []
}
rtc_source_set("unittests") {
@@ -41,7 +39,6 @@
deps = [
":aligned_array",
":aligned_malloc",
- "../..:typedefs",
"../../test:test_support",
]
}
diff --git a/rtc_base/memory/aligned_malloc.cc b/rtc_base/memory/aligned_malloc.cc
index 4e1e85c..2943a64 100644
--- a/rtc_base/memory/aligned_malloc.cc
+++ b/rtc_base/memory/aligned_malloc.cc
@@ -19,8 +19,6 @@
#include <stdint.h>
#endif
-#include "typedefs.h" // NOLINT(build/include)
-
// Reference on memory alignment:
// http://stackoverflow.com/questions/227897/solve-the-memory-alignment-in-c-interview-question-that-stumped-me
namespace webrtc {
diff --git a/rtc_base/memory/aligned_malloc_unittest.cc b/rtc_base/memory/aligned_malloc_unittest.cc
index 742a772..572af5a 100644
--- a/rtc_base/memory/aligned_malloc_unittest.cc
+++ b/rtc_base/memory/aligned_malloc_unittest.cc
@@ -19,7 +19,6 @@
#endif
#include "test/gtest.h"
-#include "typedefs.h" // NOLINT(build/include)
namespace webrtc {
diff --git a/rtc_base/onetimeevent.h b/rtc_base/onetimeevent.h
index 8c55e26..f649f15 100644
--- a/rtc_base/onetimeevent.h
+++ b/rtc_base/onetimeevent.h
@@ -12,7 +12,6 @@
#define RTC_BASE_ONETIMEEVENT_H_
#include "rtc_base/criticalsection.h"
-#include "typedefs.h" // NOLINT(build/include)
namespace webrtc {
// Provides a simple way to perform an operation (such as logging) one
diff --git a/rtc_base/random.h b/rtc_base/random.h
index 7c103cc..2faa985 100644
--- a/rtc_base/random.h
+++ b/rtc_base/random.h
@@ -15,7 +15,6 @@
#include "rtc_base/checks.h"
#include "rtc_base/constructormagic.h"
-#include "typedefs.h" // NOLINT(build/include)
namespace webrtc {
diff --git a/rtc_base/rate_statistics.h b/rtc_base/rate_statistics.h
index fe5ae82..89bfddf 100644
--- a/rtc_base/rate_statistics.h
+++ b/rtc_base/rate_statistics.h
@@ -14,7 +14,6 @@
#include <memory>
#include "absl/types/optional.h"
-#include "typedefs.h" // NOLINT(build/include)
namespace webrtc {
diff --git a/rtc_base/swap_queue.h b/rtc_base/swap_queue.h
index f794ad9..172f2f5 100644
--- a/rtc_base/swap_queue.h
+++ b/rtc_base/swap_queue.h
@@ -18,6 +18,7 @@
#include "rtc_base/checks.h"
#include "rtc_base/constructormagic.h"
#include "rtc_base/criticalsection.h"
+#include "rtc_base/system/unused.h"
namespace webrtc {
diff --git a/rtc_base/synchronization/BUILD.gn b/rtc_base/synchronization/BUILD.gn
index 9d9ea6f..447be38 100644
--- a/rtc_base/synchronization/BUILD.gn
+++ b/rtc_base/synchronization/BUILD.gn
@@ -21,7 +21,6 @@
]
deps = [
"..:macromagic",
- "../..:typedefs",
]
if (is_win) {
sources += [
diff --git a/rtc_base/synchronization/rw_lock_posix.h b/rtc_base/synchronization/rw_lock_posix.h
index 9a92bcd..a103fe7 100644
--- a/rtc_base/synchronization/rw_lock_posix.h
+++ b/rtc_base/synchronization/rw_lock_posix.h
@@ -14,7 +14,6 @@
#include <pthread.h>
#include "rtc_base/synchronization/rw_lock_wrapper.h"
-#include "typedefs.h" // NOLINT(build/include)
namespace webrtc {
diff --git a/rtc_base/system/BUILD.gn b/rtc_base/system/BUILD.gn
index 9d3fa2c..64df84f 100644
--- a/rtc_base/system/BUILD.gn
+++ b/rtc_base/system/BUILD.gn
@@ -38,7 +38,6 @@
deps = [
"..:checks",
"..:criticalsection",
- "../..:typedefs",
"../..:webrtc_common",
]
}
diff --git a/rtc_base/system/file_wrapper.h b/rtc_base/system/file_wrapper.h
index 4672cc4..5411b04 100644
--- a/rtc_base/system/file_wrapper.h
+++ b/rtc_base/system/file_wrapper.h
@@ -16,7 +16,6 @@
#include "common_types.h" // NOLINT(build/include)
#include "rtc_base/criticalsection.h"
-#include "typedefs.h" // NOLINT(build/include)
// Implementation that can read (exclusive) or write from/to a file.
diff --git a/rtc_base/task_queue_libevent.cc b/rtc_base/task_queue_libevent.cc
index b6e6353..d3b1a7c 100644
--- a/rtc_base/task_queue_libevent.cc
+++ b/rtc_base/task_queue_libevent.cc
@@ -24,6 +24,7 @@
#include "rtc_base/platform_thread.h"
#include "rtc_base/refcount.h"
#include "rtc_base/refcountedobject.h"
+#include "rtc_base/system/unused.h"
#include "rtc_base/task_queue.h"
#include "rtc_base/task_queue_posix.h"
#include "rtc_base/timeutils.h"
diff --git a/rtc_base/time/BUILD.gn b/rtc_base/time/BUILD.gn
index f8f6244..7b298ce 100644
--- a/rtc_base/time/BUILD.gn
+++ b/rtc_base/time/BUILD.gn
@@ -18,7 +18,6 @@
"timestamp_extrapolator.h",
]
deps = [
- "../..:typedefs",
"../synchronization:rw_lock_wrapper",
]
}
diff --git a/rtc_base/time/timestamp_extrapolator.h b/rtc_base/time/timestamp_extrapolator.h
index 6638184..63af57b 100644
--- a/rtc_base/time/timestamp_extrapolator.h
+++ b/rtc_base/time/timestamp_extrapolator.h
@@ -11,8 +11,9 @@
#ifndef RTC_BASE_TIME_TIMESTAMP_EXTRAPOLATOR_H_
#define RTC_BASE_TIME_TIMESTAMP_EXTRAPOLATOR_H_
+#include <stdint.h>
+
#include "rtc_base/synchronization/rw_lock_wrapper.h"
-#include "typedefs.h" // NOLINT(build/include)
namespace webrtc {