Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(163)

Unified Diff: webrtc/base/array_view.h

Issue 1470843003: Remove the special case for std::vector in rtc::ArrayView (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 5 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/base/array_view.h
diff --git a/webrtc/base/array_view.h b/webrtc/base/array_view.h
index 02676f17d187cbcbbdbba41f3612c5b5ba72e4b4..c77a6e16b4ab3f998827f382182cfe0fa63b7190 100644
--- a/webrtc/base/array_view.h
+++ b/webrtc/base/array_view.h
@@ -11,8 +11,6 @@
#ifndef WEBRTC_BASE_ARRAY_VIEW_H_
#define WEBRTC_BASE_ARRAY_VIEW_H_
-#include <vector>
-
#include "webrtc/base/checks.h"
namespace rtc {
@@ -50,12 +48,6 @@ class ArrayView final {
// std::vector).
template <typename U>
ArrayView(U& u) : ArrayView(u.data(), u.size()) {}
- // TODO(kwiberg): Remove the special case for std::vector (and the include of
- // <vector>); it is handled by the general case in C++11, since std::vector
- // has a data() method there.
- template <typename U>
- ArrayView(std::vector<U>& u)
- : ArrayView(u.empty() ? nullptr : &u[0], u.size()) {}
// Indexing, size, and iteration. These allow mutation even if the ArrayView
// is const, because the ArrayView doesn't own the array. (To prevent
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698