From de95329daa7175fa28a508681ab262596111cc57 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Niels=20M=C3=B6ller?= Date: Tue, 29 Sep 2020 09:46:21 +0200 Subject: [PATCH] Delete macros RTC_DISALLOW_ASSIGN and RTC_DISALLOW_IMPLICIT_CONSTRUCTORS The former was unused, the latter is replaced with the explicit C++11 deletions. The related RTC_DISALLOW_COPY_AND_ASSIGN is left for now, it is used in a lot more places. Bug: None Change-Id: I49503e7f2b9ff43c6285f8695833479bbc18c380 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/185500 Reviewed-by: Karl Wiberg Commit-Queue: Niels Moller Cr-Commit-Position: refs/heads/master@{#32224} --- api/transport/BUILD.gn | 1 - audio/audio_receive_stream.h | 8 ++++--- audio/audio_send_stream.h | 8 ++++--- audio/audio_state.h | 8 ++++--- audio/audio_transport_impl.h | 8 ++++--- common_audio/smoothing_filter.h | 8 ++++--- common_audio/window_generator.h | 9 ++++--- media/engine/webrtc_voice_engine.cc | 13 ++++++---- media/engine/webrtc_voice_engine.h | 15 ++++++++---- modules/audio_coding/BUILD.gn | 1 - modules/audio_processing/BUILD.gn | 6 +---- .../audio_processing/aec3/echo_canceller3.cc | 6 ++++- .../aec3/echo_canceller3_unittest.cc | 24 ++++++++++++++----- .../audio_processing/aec3/matched_filter.h | 7 +++--- .../aec3/matched_filter_lag_aggregator.h | 9 ++++--- modules/audio_processing/aec3/render_buffer.h | 7 ++++-- .../aec3/render_delay_controller.cc | 8 +++++-- modules/audio_processing/agc/BUILD.gn | 2 -- modules/audio_processing/agc2/down_sampler.h | 8 ++++--- .../agc2/noise_spectrum_estimator.h | 8 ++++--- .../audio_processing/agc2/signal_classifier.h | 14 +++++++---- .../include/audio_processing.h | 1 + modules/audio_processing/include/config.h | 2 -- .../logging/apm_data_dumper.h | 6 +++-- .../test/aec_dump_based_simulator.h | 7 ++++-- .../test/audio_processing_simulator.h | 8 ++++--- .../test/wav_based_simulator.h | 8 ++++--- .../congestion_controller/goog_cc/BUILD.gn | 1 - .../goog_cc/delay_based_bwe.h | 7 ++++-- .../goog_cc/goog_cc_network_control.h | 8 ++++--- .../receive_side_congestion_controller.h | 8 ++++--- .../desktop_capture/win/scoped_gdi_object.h | 14 ++++++----- .../remote_bitrate_estimator/inter_arrival.h | 8 +++---- .../remote_bitrate_estimator_abs_send_time.h | 10 +++++--- .../remote_bitrate_estimator_single_stream.h | 10 +++++--- .../test/bwe_test_logging.h | 7 +++--- modules/rtp_rtcp/source/rtcp_sender.cc | 7 +++--- modules/rtp_rtcp/source/rtcp_sender.h | 8 ++++--- modules/rtp_rtcp/source/rtp_packet_history.h | 8 ++++--- modules/rtp_rtcp/source/rtp_sender.h | 7 +++--- modules/rtp_rtcp/source/rtp_sender_audio.h | 8 ++++--- .../multiplex/multiplex_decoder_adapter.cc | 15 +++++++----- modules/video_coding/frame_buffer2.h | 7 +++--- pc/audio_track.h | 7 ++++-- pc/ice_transport.h | 6 +++-- pc/remote_audio_source.cc | 8 ++++--- rtc_base/BUILD.gn | 3 --- rtc_base/constructor_magic.h | 16 +------------ rtc_base/deprecated/signal_thread.h | 14 +++++++---- rtc_base/random.h | 7 +++--- rtc_base/rate_limiter.h | 8 ++++--- rtc_base/weak_ptr.h | 5 +++- rtc_tools/rtp_generator/rtp_generator.h | 9 +++---- video/BUILD.gn | 1 - video/adaptation/BUILD.gn | 1 - 55 files changed, 256 insertions(+), 172 deletions(-) diff --git a/api/transport/BUILD.gn b/api/transport/BUILD.gn index d2da4453bf..6a7cc57cd2 100644 --- a/api/transport/BUILD.gn +++ b/api/transport/BUILD.gn @@ -144,7 +144,6 @@ if (rtc_include_tests) { deps = [ ":stun_types", "../../rtc_base", - "../../rtc_base:macromagic", "../../rtc_base:rtc_base_approved", "../../test:test_support", "//testing/gtest", diff --git a/audio/audio_receive_stream.h b/audio/audio_receive_stream.h index eeb876cb91..32f8b60d58 100644 --- a/audio/audio_receive_stream.h +++ b/audio/audio_receive_stream.h @@ -21,7 +21,6 @@ #include "call/audio_receive_stream.h" #include "call/syncable.h" #include "modules/rtp_rtcp/source/source_tracker.h" -#include "rtc_base/constructor_magic.h" #include "rtc_base/thread_checker.h" #include "system_wrappers/include/clock.h" @@ -61,6 +60,11 @@ class AudioReceiveStream final : public webrtc::AudioReceiveStream, const rtc::scoped_refptr& audio_state, webrtc::RtcEventLog* event_log, std::unique_ptr channel_receive); + + AudioReceiveStream() = delete; + AudioReceiveStream(const AudioReceiveStream&) = delete; + AudioReceiveStream& operator=(const AudioReceiveStream&) = delete; + ~AudioReceiveStream() override; // webrtc::AudioReceiveStream implementation. @@ -113,8 +117,6 @@ class AudioReceiveStream final : public webrtc::AudioReceiveStream, bool playing_ RTC_GUARDED_BY(worker_thread_checker_) = false; std::unique_ptr rtp_stream_receiver_; - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(AudioReceiveStream); }; } // namespace internal } // namespace webrtc diff --git a/audio/audio_send_stream.h b/audio/audio_send_stream.h index 7bc3183123..12fcb9f21a 100644 --- a/audio/audio_send_stream.h +++ b/audio/audio_send_stream.h @@ -21,7 +21,6 @@ #include "call/audio_state.h" #include "call/bitrate_allocator.h" #include "modules/rtp_rtcp/source/rtp_rtcp_interface.h" -#include "rtc_base/constructor_magic.h" #include "rtc_base/experiments/struct_parameters_parser.h" #include "rtc_base/race_checker.h" #include "rtc_base/synchronization/mutex.h" @@ -75,6 +74,11 @@ class AudioSendStream final : public webrtc::AudioSendStream, RtcEventLog* event_log, const absl::optional& suspended_rtp_state, std::unique_ptr channel_send); + + AudioSendStream() = delete; + AudioSendStream(const AudioSendStream&) = delete; + AudioSendStream& operator=(const AudioSendStream&) = delete; + ~AudioSendStream() override; // webrtc::AudioSendStream implementation. @@ -206,8 +210,6 @@ class AudioSendStream final : public webrtc::AudioSendStream, size_t total_packet_overhead_bytes_ RTC_GUARDED_BY(worker_queue_) = 0; absl::optional> frame_length_range_ RTC_GUARDED_BY(worker_queue_); - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(AudioSendStream); }; } // namespace internal } // namespace webrtc diff --git a/audio/audio_state.h b/audio/audio_state.h index 70c7208320..5e766428d9 100644 --- a/audio/audio_state.h +++ b/audio/audio_state.h @@ -18,7 +18,6 @@ #include "audio/audio_transport_impl.h" #include "audio/null_audio_poller.h" #include "call/audio_state.h" -#include "rtc_base/constructor_magic.h" #include "rtc_base/ref_count.h" #include "rtc_base/thread_checker.h" @@ -32,6 +31,11 @@ namespace internal { class AudioState : public webrtc::AudioState { public: explicit AudioState(const AudioState::Config& config); + + AudioState() = delete; + AudioState(const AudioState&) = delete; + AudioState& operator=(const AudioState&) = delete; + ~AudioState() override; AudioProcessing* audio_processing() override; @@ -82,8 +86,6 @@ class AudioState : public webrtc::AudioState { size_t num_channels = 0; }; std::map sending_streams_; - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(AudioState); }; } // namespace internal } // namespace webrtc diff --git a/audio/audio_transport_impl.h b/audio/audio_transport_impl.h index 1643a29970..5b885bdc6c 100644 --- a/audio/audio_transport_impl.h +++ b/audio/audio_transport_impl.h @@ -19,7 +19,6 @@ #include "modules/audio_device/include/audio_device.h" #include "modules/audio_processing/include/audio_processing.h" #include "modules/audio_processing/typing_detection.h" -#include "rtc_base/constructor_magic.h" #include "rtc_base/synchronization/mutex.h" #include "rtc_base/thread_annotations.h" @@ -30,6 +29,11 @@ class AudioSender; class AudioTransportImpl : public AudioTransport { public: AudioTransportImpl(AudioMixer* mixer, AudioProcessing* audio_processing); + + AudioTransportImpl() = delete; + AudioTransportImpl(const AudioTransportImpl&) = delete; + AudioTransportImpl& operator=(const AudioTransportImpl&) = delete; + ~AudioTransportImpl() override; int32_t RecordedDataIsAvailable(const void* audioSamples, @@ -85,8 +89,6 @@ class AudioTransportImpl : public AudioTransport { AudioFrame mixed_frame_; // Converts mixed audio to the audio device output rate. PushResampler render_resampler_; - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(AudioTransportImpl); }; } // namespace webrtc diff --git a/common_audio/smoothing_filter.h b/common_audio/smoothing_filter.h index e5f561ecf2..e96d52a6f7 100644 --- a/common_audio/smoothing_filter.h +++ b/common_audio/smoothing_filter.h @@ -14,7 +14,6 @@ #include #include "absl/types/optional.h" -#include "rtc_base/constructor_magic.h" namespace webrtc { @@ -42,6 +41,11 @@ class SmoothingFilterImpl final : public SmoothingFilter { // will be set to |init_time_ms| first and can be changed through // |SetTimeConstantMs|. explicit SmoothingFilterImpl(int init_time_ms); + + SmoothingFilterImpl() = delete; + SmoothingFilterImpl(const SmoothingFilterImpl&) = delete; + SmoothingFilterImpl& operator=(const SmoothingFilterImpl&) = delete; + ~SmoothingFilterImpl() override; void AddSample(float sample) override; @@ -64,8 +68,6 @@ class SmoothingFilterImpl final : public SmoothingFilter { float alpha_; float state_; int64_t last_state_time_ms_; - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(SmoothingFilterImpl); }; } // namespace webrtc diff --git a/common_audio/window_generator.h b/common_audio/window_generator.h index 0cbe24a402..c0a89c4f93 100644 --- a/common_audio/window_generator.h +++ b/common_audio/window_generator.h @@ -13,18 +13,17 @@ #include -#include "rtc_base/constructor_magic.h" - namespace webrtc { // Helper class with generators for various signal transform windows. class WindowGenerator { public: + WindowGenerator() = delete; + WindowGenerator(const WindowGenerator&) = delete; + WindowGenerator& operator=(const WindowGenerator&) = delete; + static void Hanning(int length, float* window); static void KaiserBesselDerived(float alpha, size_t length, float* window); - - private: - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(WindowGenerator); }; } // namespace webrtc diff --git a/media/engine/webrtc_voice_engine.cc b/media/engine/webrtc_voice_engine.cc index 2c9e15df28..52a8f3dcc6 100644 --- a/media/engine/webrtc_voice_engine.cc +++ b/media/engine/webrtc_voice_engine.cc @@ -33,7 +33,6 @@ #include "modules/audio_processing/include/audio_processing.h" #include "rtc_base/arraysize.h" #include "rtc_base/byte_order.h" -#include "rtc_base/constructor_magic.h" #include "rtc_base/experiments/field_trial_parser.h" #include "rtc_base/experiments/field_trial_units.h" #include "rtc_base/experiments/struct_parameters_parser.h" @@ -802,6 +801,10 @@ class WebRtcVoiceMediaChannel::WebRtcAudioSendStream stream_ = call_->CreateAudioSendStream(config_); } + WebRtcAudioSendStream() = delete; + WebRtcAudioSendStream(const WebRtcAudioSendStream&) = delete; + WebRtcAudioSendStream& operator=(const WebRtcAudioSendStream&) = delete; + ~WebRtcAudioSendStream() override { RTC_DCHECK(worker_thread_checker_.IsCurrent()); ClearSource(); @@ -1143,8 +1146,6 @@ class WebRtcVoiceMediaChannel::WebRtcAudioSendStream // TODO(webrtc:11717): Remove this once audio_network_adaptor in AudioOptions // has been removed. absl::optional audio_network_adaptor_config_from_options_; - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(WebRtcAudioSendStream); }; class WebRtcVoiceMediaChannel::WebRtcAudioReceiveStream { @@ -1193,6 +1194,10 @@ class WebRtcVoiceMediaChannel::WebRtcAudioReceiveStream { RecreateAudioReceiveStream(); } + WebRtcAudioReceiveStream() = delete; + WebRtcAudioReceiveStream(const WebRtcAudioReceiveStream&) = delete; + WebRtcAudioReceiveStream& operator=(const WebRtcAudioReceiveStream&) = delete; + ~WebRtcAudioReceiveStream() { RTC_DCHECK(worker_thread_checker_.IsCurrent()); call_->DestroyAudioReceiveStream(stream_); @@ -1356,8 +1361,6 @@ class WebRtcVoiceMediaChannel::WebRtcAudioReceiveStream { bool playout_ = false; float output_volume_ = 1.0; std::unique_ptr raw_audio_sink_; - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(WebRtcAudioReceiveStream); }; WebRtcVoiceMediaChannel::WebRtcVoiceMediaChannel( diff --git a/media/engine/webrtc_voice_engine.h b/media/engine/webrtc_voice_engine.h index f805d6c916..0d3c5fe79a 100644 --- a/media/engine/webrtc_voice_engine.h +++ b/media/engine/webrtc_voice_engine.h @@ -26,7 +26,6 @@ #include "media/base/media_engine.h" #include "media/base/rtp_utils.h" #include "rtc_base/buffer.h" -#include "rtc_base/constructor_magic.h" #include "rtc_base/network_route.h" #include "rtc_base/task_queue.h" #include "rtc_base/thread_checker.h" @@ -52,6 +51,11 @@ class WebRtcVoiceEngine final : public VoiceEngineInterface { rtc::scoped_refptr audio_mixer, rtc::scoped_refptr audio_processing, const webrtc::WebRtcKeyValueConfig& trials); + + WebRtcVoiceEngine() = delete; + WebRtcVoiceEngine(const WebRtcVoiceEngine&) = delete; + WebRtcVoiceEngine& operator=(const WebRtcVoiceEngine&) = delete; + ~WebRtcVoiceEngine() override; // Does initialization that needs to occur on the worker thread. @@ -133,8 +137,6 @@ class WebRtcVoiceEngine final : public VoiceEngineInterface { // redundancy for opus audio. const bool audio_red_for_opus_trial_enabled_; const bool minimized_remsampling_on_mobile_trial_enabled_; - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(WebRtcVoiceEngine); }; // WebRtcVoiceMediaChannel is an implementation of VoiceMediaChannel that uses @@ -147,6 +149,11 @@ class WebRtcVoiceMediaChannel final : public VoiceMediaChannel, const AudioOptions& options, const webrtc::CryptoOptions& crypto_options, webrtc::Call* call); + + WebRtcVoiceMediaChannel() = delete; + WebRtcVoiceMediaChannel(const WebRtcVoiceMediaChannel&) = delete; + WebRtcVoiceMediaChannel& operator=(const WebRtcVoiceMediaChannel&) = delete; + ~WebRtcVoiceMediaChannel() override; const AudioOptions& options() const { return options_; } @@ -339,8 +346,6 @@ class WebRtcVoiceMediaChannel final : public VoiceMediaChannel, unsignaled_frame_decryptor_; const bool audio_red_for_opus_trial_enabled_; - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(WebRtcVoiceMediaChannel); }; } // namespace cricket diff --git a/modules/audio_coding/BUILD.gn b/modules/audio_coding/BUILD.gn index 33540333f5..cdf7821d6f 100644 --- a/modules/audio_coding/BUILD.gn +++ b/modules/audio_coding/BUILD.gn @@ -793,7 +793,6 @@ rtc_library("webrtc_multiopus") { "../../api/units:time_delta", "../../rtc_base:checks", "../../rtc_base:logging", - "../../rtc_base:macromagic", "../../rtc_base:rtc_base_approved", "../../rtc_base:safe_minmax", "../../rtc_base:stringutils", diff --git a/modules/audio_processing/BUILD.gn b/modules/audio_processing/BUILD.gn index 83fdcef960..dbb1882de2 100644 --- a/modules/audio_processing/BUILD.gn +++ b/modules/audio_processing/BUILD.gn @@ -25,10 +25,7 @@ rtc_library("config") { "include/config.cc", "include/config.h", ] - deps = [ - "../../rtc_base:macromagic", - "../../rtc_base/system:rtc_export", - ] + deps = [ "../../rtc_base/system:rtc_export" ] } rtc_library("api") { @@ -47,7 +44,6 @@ rtc_library("api") { "../../api/audio:audio_frame_api", "../../api/audio:echo_control", "../../rtc_base:deprecation", - "../../rtc_base:macromagic", "../../rtc_base:rtc_base_approved", "../../rtc_base/system:arch", "../../rtc_base/system:file_wrapper", diff --git a/modules/audio_processing/aec3/echo_canceller3.cc b/modules/audio_processing/aec3/echo_canceller3.cc index a0e1fc22a3..d96abc979f 100644 --- a/modules/audio_processing/aec3/echo_canceller3.cc +++ b/modules/audio_processing/aec3/echo_canceller3.cc @@ -564,6 +564,11 @@ class EchoCanceller3::RenderWriter { Aec3RenderQueueItemVerifier>* render_transfer_queue, size_t num_bands, size_t num_channels); + + RenderWriter() = delete; + RenderWriter(const RenderWriter&) = delete; + RenderWriter& operator=(const RenderWriter&) = delete; + ~RenderWriter(); void Insert(const AudioBuffer& input); @@ -575,7 +580,6 @@ class EchoCanceller3::RenderWriter { std::vector>> render_queue_input_frame_; SwapQueue>>, Aec3RenderQueueItemVerifier>* render_transfer_queue_; - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(RenderWriter); }; EchoCanceller3::RenderWriter::RenderWriter( diff --git a/modules/audio_processing/aec3/echo_canceller3_unittest.cc b/modules/audio_processing/aec3/echo_canceller3_unittest.cc index 04d93e4db4..a02cfa3904 100644 --- a/modules/audio_processing/aec3/echo_canceller3_unittest.cc +++ b/modules/audio_processing/aec3/echo_canceller3_unittest.cc @@ -108,6 +108,13 @@ bool VerifyOutputFrameBitexactness(rtc::ArrayView reference, class CaptureTransportVerificationProcessor : public BlockProcessor { public: explicit CaptureTransportVerificationProcessor(size_t num_bands) {} + + CaptureTransportVerificationProcessor() = delete; + CaptureTransportVerificationProcessor( + const CaptureTransportVerificationProcessor&) = delete; + CaptureTransportVerificationProcessor& operator=( + const CaptureTransportVerificationProcessor&) = delete; + ~CaptureTransportVerificationProcessor() override = default; void ProcessCapture( @@ -124,9 +131,6 @@ class CaptureTransportVerificationProcessor : public BlockProcessor { void GetMetrics(EchoControl::Metrics* metrics) const override {} void SetAudioBufferDelay(int delay_ms) override {} - - private: - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(CaptureTransportVerificationProcessor); }; // Class for testing that the render data is properly received by the block @@ -134,6 +138,13 @@ class CaptureTransportVerificationProcessor : public BlockProcessor { class RenderTransportVerificationProcessor : public BlockProcessor { public: explicit RenderTransportVerificationProcessor(size_t num_bands) {} + + RenderTransportVerificationProcessor() = delete; + RenderTransportVerificationProcessor( + const RenderTransportVerificationProcessor&) = delete; + RenderTransportVerificationProcessor& operator=( + const RenderTransportVerificationProcessor&) = delete; + ~RenderTransportVerificationProcessor() override = default; void ProcessCapture( @@ -161,7 +172,6 @@ class RenderTransportVerificationProcessor : public BlockProcessor { private: std::deque>>> received_render_blocks_; - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(RenderTransportVerificationProcessor); }; class EchoCanceller3Tester { @@ -184,6 +194,10 @@ class EchoCanceller3Tester { fullband_frame_length_ * 100, 1) {} + EchoCanceller3Tester() = delete; + EchoCanceller3Tester(const EchoCanceller3Tester&) = delete; + EchoCanceller3Tester& operator=(const EchoCanceller3Tester&) = delete; + // Verifies that the capture data is properly received by the block processor // and that the processor data is properly passed to the EchoCanceller3 // output. @@ -602,8 +616,6 @@ class EchoCanceller3Tester { const int fullband_frame_length_; AudioBuffer capture_buffer_; AudioBuffer render_buffer_; - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(EchoCanceller3Tester); }; std::string ProduceDebugText(int sample_rate_hz) { diff --git a/modules/audio_processing/aec3/matched_filter.h b/modules/audio_processing/aec3/matched_filter.h index 954e4784f2..fa44eb27fd 100644 --- a/modules/audio_processing/aec3/matched_filter.h +++ b/modules/audio_processing/aec3/matched_filter.h @@ -17,7 +17,6 @@ #include "api/array_view.h" #include "modules/audio_processing/aec3/aec3_common.h" -#include "rtc_base/constructor_magic.h" #include "rtc_base/system/arch.h" namespace webrtc { @@ -104,6 +103,10 @@ class MatchedFilter { float smoothing, float matching_filter_threshold); + MatchedFilter() = delete; + MatchedFilter(const MatchedFilter&) = delete; + MatchedFilter& operator=(const MatchedFilter&) = delete; + ~MatchedFilter(); // Updates the correlation with the values in the capture buffer. @@ -139,8 +142,6 @@ class MatchedFilter { const float excitation_limit_; const float smoothing_; const float matching_filter_threshold_; - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(MatchedFilter); }; } // namespace webrtc diff --git a/modules/audio_processing/aec3/matched_filter_lag_aggregator.h b/modules/audio_processing/aec3/matched_filter_lag_aggregator.h index 0cc7789d11..d48011e477 100644 --- a/modules/audio_processing/aec3/matched_filter_lag_aggregator.h +++ b/modules/audio_processing/aec3/matched_filter_lag_aggregator.h @@ -17,7 +17,6 @@ #include "api/audio/echo_canceller3_config.h" #include "modules/audio_processing/aec3/delay_estimate.h" #include "modules/audio_processing/aec3/matched_filter.h" -#include "rtc_base/constructor_magic.h" namespace webrtc { @@ -31,6 +30,12 @@ class MatchedFilterLagAggregator { ApmDataDumper* data_dumper, size_t max_filter_lag, const EchoCanceller3Config::Delay::DelaySelectionThresholds& thresholds); + + MatchedFilterLagAggregator() = delete; + MatchedFilterLagAggregator(const MatchedFilterLagAggregator&) = delete; + MatchedFilterLagAggregator& operator=(const MatchedFilterLagAggregator&) = + delete; + ~MatchedFilterLagAggregator(); // Resets the aggregator. @@ -47,8 +52,6 @@ class MatchedFilterLagAggregator { int histogram_data_index_ = 0; bool significant_candidate_found_ = false; const EchoCanceller3Config::Delay::DelaySelectionThresholds thresholds_; - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(MatchedFilterLagAggregator); }; } // namespace webrtc diff --git a/modules/audio_processing/aec3/render_buffer.h b/modules/audio_processing/aec3/render_buffer.h index 3422df35ee..b8be6f517a 100644 --- a/modules/audio_processing/aec3/render_buffer.h +++ b/modules/audio_processing/aec3/render_buffer.h @@ -23,7 +23,6 @@ #include "modules/audio_processing/aec3/fft_data.h" #include "modules/audio_processing/aec3/spectrum_buffer.h" #include "rtc_base/checks.h" -#include "rtc_base/constructor_magic.h" namespace webrtc { @@ -33,6 +32,11 @@ class RenderBuffer { RenderBuffer(BlockBuffer* block_buffer, SpectrumBuffer* spectrum_buffer, FftBuffer* fft_buffer); + + RenderBuffer() = delete; + RenderBuffer(const RenderBuffer&) = delete; + RenderBuffer& operator=(const RenderBuffer&) = delete; + ~RenderBuffer(); // Get a block. @@ -105,7 +109,6 @@ class RenderBuffer { const SpectrumBuffer* const spectrum_buffer_; const FftBuffer* const fft_buffer_; bool render_activity_ = false; - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(RenderBuffer); }; } // namespace webrtc diff --git a/modules/audio_processing/aec3/render_delay_controller.cc b/modules/audio_processing/aec3/render_delay_controller.cc index c42d22bdca..3677085d81 100644 --- a/modules/audio_processing/aec3/render_delay_controller.cc +++ b/modules/audio_processing/aec3/render_delay_controller.cc @@ -25,7 +25,6 @@ #include "modules/audio_processing/logging/apm_data_dumper.h" #include "rtc_base/atomic_ops.h" #include "rtc_base/checks.h" -#include "rtc_base/constructor_magic.h" namespace webrtc { @@ -36,6 +35,12 @@ class RenderDelayControllerImpl final : public RenderDelayController { RenderDelayControllerImpl(const EchoCanceller3Config& config, int sample_rate_hz, size_t num_capture_channels); + + RenderDelayControllerImpl() = delete; + RenderDelayControllerImpl(const RenderDelayControllerImpl&) = delete; + RenderDelayControllerImpl& operator=(const RenderDelayControllerImpl&) = + delete; + ~RenderDelayControllerImpl() override; void Reset(bool reset_delay_confidence) override; void LogRenderCall() override; @@ -57,7 +62,6 @@ class RenderDelayControllerImpl final : public RenderDelayController { size_t capture_call_counter_ = 0; int delay_change_counter_ = 0; DelayEstimate::Quality last_delay_estimate_quality_; - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(RenderDelayControllerImpl); }; DelayEstimate ComputeBufferDelay( diff --git a/modules/audio_processing/agc/BUILD.gn b/modules/audio_processing/agc/BUILD.gn index e5b3980abe..8235456dd9 100644 --- a/modules/audio_processing/agc/BUILD.gn +++ b/modules/audio_processing/agc/BUILD.gn @@ -29,7 +29,6 @@ rtc_library("agc") { "../../../rtc_base:checks", "../../../rtc_base:gtest_prod", "../../../rtc_base:logging", - "../../../rtc_base:macromagic", "../../../rtc_base:rtc_base_approved", "../../../rtc_base:safe_minmax", "../../../system_wrappers:field_trial", @@ -51,7 +50,6 @@ rtc_library("level_estimation") { ] deps = [ "../../../rtc_base:checks", - "../../../rtc_base:macromagic", "../vad", ] } diff --git a/modules/audio_processing/agc2/down_sampler.h b/modules/audio_processing/agc2/down_sampler.h index 61d1b005e0..be7cbb3da7 100644 --- a/modules/audio_processing/agc2/down_sampler.h +++ b/modules/audio_processing/agc2/down_sampler.h @@ -13,7 +13,6 @@ #include "api/array_view.h" #include "modules/audio_processing/agc2/biquad_filter.h" -#include "rtc_base/constructor_magic.h" namespace webrtc { @@ -22,6 +21,11 @@ class ApmDataDumper; class DownSampler { public: explicit DownSampler(ApmDataDumper* data_dumper); + + DownSampler() = delete; + DownSampler(const DownSampler&) = delete; + DownSampler& operator=(const DownSampler&) = delete; + void Initialize(int sample_rate_hz); void DownSample(rtc::ArrayView in, rtc::ArrayView out); @@ -31,8 +35,6 @@ class DownSampler { int sample_rate_hz_; int down_sampling_factor_; BiQuadFilter low_pass_filter_; - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(DownSampler); }; } // namespace webrtc diff --git a/modules/audio_processing/agc2/noise_spectrum_estimator.h b/modules/audio_processing/agc2/noise_spectrum_estimator.h index b22f9bb398..e9895f0b1e 100644 --- a/modules/audio_processing/agc2/noise_spectrum_estimator.h +++ b/modules/audio_processing/agc2/noise_spectrum_estimator.h @@ -12,7 +12,6 @@ #define MODULES_AUDIO_PROCESSING_AGC2_NOISE_SPECTRUM_ESTIMATOR_H_ #include "api/array_view.h" -#include "rtc_base/constructor_magic.h" namespace webrtc { @@ -21,6 +20,11 @@ class ApmDataDumper; class NoiseSpectrumEstimator { public: explicit NoiseSpectrumEstimator(ApmDataDumper* data_dumper); + + NoiseSpectrumEstimator() = delete; + NoiseSpectrumEstimator(const NoiseSpectrumEstimator&) = delete; + NoiseSpectrumEstimator& operator=(const NoiseSpectrumEstimator&) = delete; + void Initialize(); void Update(rtc::ArrayView spectrum, bool first_update); @@ -31,8 +35,6 @@ class NoiseSpectrumEstimator { private: ApmDataDumper* data_dumper_; float noise_spectrum_[65]; - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(NoiseSpectrumEstimator); }; } // namespace webrtc diff --git a/modules/audio_processing/agc2/signal_classifier.h b/modules/audio_processing/agc2/signal_classifier.h index ae288ae775..20cce920f0 100644 --- a/modules/audio_processing/agc2/signal_classifier.h +++ b/modules/audio_processing/agc2/signal_classifier.h @@ -18,7 +18,6 @@ #include "common_audio/third_party/ooura/fft_size_128/ooura_fft.h" #include "modules/audio_processing/agc2/down_sampler.h" #include "modules/audio_processing/agc2/noise_spectrum_estimator.h" -#include "rtc_base/constructor_magic.h" namespace webrtc { @@ -30,6 +29,11 @@ class SignalClassifier { enum class SignalType { kNonStationary, kStationary }; explicit SignalClassifier(ApmDataDumper* data_dumper); + + SignalClassifier() = delete; + SignalClassifier(const SignalClassifier&) = delete; + SignalClassifier& operator=(const SignalClassifier&) = delete; + ~SignalClassifier(); void Initialize(int sample_rate_hz); @@ -39,6 +43,11 @@ class SignalClassifier { class FrameExtender { public: FrameExtender(size_t frame_size, size_t extended_frame_size); + + FrameExtender() = delete; + FrameExtender(const FrameExtender&) = delete; + FrameExtender& operator=(const FrameExtender&) = delete; + ~FrameExtender(); void ExtendFrame(rtc::ArrayView x, @@ -46,8 +55,6 @@ class SignalClassifier { private: std::vector x_old_; - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(FrameExtender); }; ApmDataDumper* const data_dumper_; @@ -59,7 +66,6 @@ class SignalClassifier { int consistent_classification_counter_; SignalType last_signal_type_; const OouraFft ooura_fft_; - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(SignalClassifier); }; } // namespace webrtc diff --git a/modules/audio_processing/include/audio_processing.h b/modules/audio_processing/include/audio_processing.h index 32401afd6d..43c40fff7f 100644 --- a/modules/audio_processing/include/audio_processing.h +++ b/modules/audio_processing/include/audio_processing.h @@ -31,6 +31,7 @@ #include "modules/audio_processing/include/audio_processing_statistics.h" #include "modules/audio_processing/include/config.h" #include "rtc_base/arraysize.h" +#include "rtc_base/constructor_magic.h" #include "rtc_base/deprecation.h" #include "rtc_base/ref_count.h" #include "rtc_base/system/file_wrapper.h" diff --git a/modules/audio_processing/include/config.h b/modules/audio_processing/include/config.h index 8a245864ee..7fab17831c 100644 --- a/modules/audio_processing/include/config.h +++ b/modules/audio_processing/include/config.h @@ -13,7 +13,6 @@ #include -#include "rtc_base/constructor_magic.h" #include "rtc_base/system/rtc_export.h" namespace webrtc { @@ -105,7 +104,6 @@ class RTC_EXPORT Config { typedef std::map OptionMap; OptionMap options_; - // RTC_DISALLOW_COPY_AND_ASSIGN Config(const Config&); void operator=(const Config&); }; diff --git a/modules/audio_processing/logging/apm_data_dumper.h b/modules/audio_processing/logging/apm_data_dumper.h index 17a5c87716..1824fdd2a9 100644 --- a/modules/audio_processing/logging/apm_data_dumper.h +++ b/modules/audio_processing/logging/apm_data_dumper.h @@ -26,7 +26,6 @@ #include "common_audio/wav_file.h" #include "rtc_base/checks.h" #endif -#include "rtc_base/constructor_magic.h" // Check to verify that the define is properly set. #if !defined(WEBRTC_APM_DEBUG_DUMP) || \ @@ -52,6 +51,10 @@ class ApmDataDumper { // instances of the code. explicit ApmDataDumper(int instance_index); + ApmDataDumper() = delete; + ApmDataDumper(const ApmDataDumper&) = delete; + ApmDataDumper& operator=(const ApmDataDumper&) = delete; + ~ApmDataDumper(); // Activates or deactivate the dumping functionality. @@ -277,7 +280,6 @@ class ApmDataDumper { int num_channels, WavFile::SampleFormat format); #endif - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(ApmDataDumper); }; } // namespace webrtc diff --git a/modules/audio_processing/test/aec_dump_based_simulator.h b/modules/audio_processing/test/aec_dump_based_simulator.h index 092b82bdbc..c8d82e6fc3 100644 --- a/modules/audio_processing/test/aec_dump_based_simulator.h +++ b/modules/audio_processing/test/aec_dump_based_simulator.h @@ -15,7 +15,6 @@ #include #include "modules/audio_processing/test/audio_processing_simulator.h" -#include "rtc_base/constructor_magic.h" #include "rtc_base/ignore_wundef.h" RTC_PUSH_IGNORING_WUNDEF() @@ -35,6 +34,11 @@ class AecDumpBasedSimulator final : public AudioProcessingSimulator { AecDumpBasedSimulator(const SimulationSettings& settings, rtc::scoped_refptr audio_processing, std::unique_ptr ap_builder); + + AecDumpBasedSimulator() = delete; + AecDumpBasedSimulator(const AecDumpBasedSimulator&) = delete; + AecDumpBasedSimulator& operator=(const AecDumpBasedSimulator&) = delete; + ~AecDumpBasedSimulator() override; // Processes the messages in the aecdump file. @@ -65,7 +69,6 @@ class AecDumpBasedSimulator final : public AudioProcessingSimulator { bool artificial_nearend_eof_reported_ = false; InterfaceType interface_used_ = InterfaceType::kNotSpecified; std::unique_ptr call_order_output_file_; - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(AecDumpBasedSimulator); }; } // namespace test diff --git a/modules/audio_processing/test/audio_processing_simulator.h b/modules/audio_processing/test/audio_processing_simulator.h index 8579f4b4d0..63e644a9fa 100644 --- a/modules/audio_processing/test/audio_processing_simulator.h +++ b/modules/audio_processing/test/audio_processing_simulator.h @@ -24,7 +24,6 @@ #include "modules/audio_processing/test/api_call_statistics.h" #include "modules/audio_processing/test/fake_recording_device.h" #include "modules/audio_processing/test/test_utils.h" -#include "rtc_base/constructor_magic.h" #include "rtc_base/task_queue_for_test.h" #include "rtc_base/time_utils.h" @@ -153,6 +152,11 @@ class AudioProcessingSimulator { AudioProcessingSimulator(const SimulationSettings& settings, rtc::scoped_refptr audio_processing, std::unique_ptr ap_builder); + + AudioProcessingSimulator() = delete; + AudioProcessingSimulator(const AudioProcessingSimulator&) = delete; + AudioProcessingSimulator& operator=(const AudioProcessingSimulator&) = delete; + virtual ~AudioProcessingSimulator(); // Processes the data in the input. @@ -222,8 +226,6 @@ class AudioProcessingSimulator { FakeRecordingDevice fake_recording_device_; TaskQueueForTest worker_queue_; - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(AudioProcessingSimulator); }; } // namespace test diff --git a/modules/audio_processing/test/wav_based_simulator.h b/modules/audio_processing/test/wav_based_simulator.h index 3adbe7022c..286ce1f587 100644 --- a/modules/audio_processing/test/wav_based_simulator.h +++ b/modules/audio_processing/test/wav_based_simulator.h @@ -14,7 +14,6 @@ #include #include "modules/audio_processing/test/audio_processing_simulator.h" -#include "rtc_base/constructor_magic.h" namespace webrtc { namespace test { @@ -25,6 +24,11 @@ class WavBasedSimulator final : public AudioProcessingSimulator { WavBasedSimulator(const SimulationSettings& settings, rtc::scoped_refptr audio_processing, std::unique_ptr ap_builder); + + WavBasedSimulator() = delete; + WavBasedSimulator(const WavBasedSimulator&) = delete; + WavBasedSimulator& operator=(const WavBasedSimulator&) = delete; + ~WavBasedSimulator() override; // Processes the WAV input. @@ -46,8 +50,6 @@ class WavBasedSimulator final : public AudioProcessingSimulator { const std::string& filename); std::vector call_chain_; - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(WavBasedSimulator); }; } // namespace test diff --git a/modules/congestion_controller/goog_cc/BUILD.gn b/modules/congestion_controller/goog_cc/BUILD.gn index 9bee7b298f..00e00f404b 100644 --- a/modules/congestion_controller/goog_cc/BUILD.gn +++ b/modules/congestion_controller/goog_cc/BUILD.gn @@ -44,7 +44,6 @@ rtc_library("goog_cc") { "../../../logging:rtc_event_pacing", "../../../rtc_base:checks", "../../../rtc_base:logging", - "../../../rtc_base:macromagic", "../../../rtc_base/experiments:alr_experiment", "../../../rtc_base/experiments:field_trial_parser", "../../../rtc_base/experiments:rate_control_settings", diff --git a/modules/congestion_controller/goog_cc/delay_based_bwe.h b/modules/congestion_controller/goog_cc/delay_based_bwe.h index 25f5a3be72..74650dc822 100644 --- a/modules/congestion_controller/goog_cc/delay_based_bwe.h +++ b/modules/congestion_controller/goog_cc/delay_based_bwe.h @@ -26,7 +26,6 @@ #include "modules/remote_bitrate_estimator/aimd_rate_control.h" #include "modules/remote_bitrate_estimator/include/bwe_defines.h" #include "modules/remote_bitrate_estimator/inter_arrival.h" -#include "rtc_base/constructor_magic.h" #include "rtc_base/experiments/struct_parameters_parser.h" #include "rtc_base/race_checker.h" @@ -78,6 +77,11 @@ class DelayBasedBwe { explicit DelayBasedBwe(const WebRtcKeyValueConfig* key_value_config, RtcEventLog* event_log, NetworkStatePredictor* network_state_predictor); + + DelayBasedBwe() = delete; + DelayBasedBwe(const DelayBasedBwe&) = delete; + DelayBasedBwe& operator=(const DelayBasedBwe&) = delete; + virtual ~DelayBasedBwe(); Result IncomingPacketFeedbackVector( @@ -143,7 +147,6 @@ class DelayBasedBwe { bool has_once_detected_overuse_; BandwidthUsage prev_state_; bool alr_limited_backoff_enabled_; - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(DelayBasedBwe); }; } // namespace webrtc diff --git a/modules/congestion_controller/goog_cc/goog_cc_network_control.h b/modules/congestion_controller/goog_cc/goog_cc_network_control.h index 1e4dcf62e1..6dd70c8969 100644 --- a/modules/congestion_controller/goog_cc/goog_cc_network_control.h +++ b/modules/congestion_controller/goog_cc/goog_cc_network_control.h @@ -33,7 +33,6 @@ #include "modules/congestion_controller/goog_cc/delay_based_bwe.h" #include "modules/congestion_controller/goog_cc/probe_controller.h" #include "modules/congestion_controller/goog_cc/send_side_bandwidth_estimation.h" -#include "rtc_base/constructor_magic.h" #include "rtc_base/experiments/field_trial_parser.h" #include "rtc_base/experiments/rate_control_settings.h" @@ -48,6 +47,11 @@ class GoogCcNetworkController : public NetworkControllerInterface { public: GoogCcNetworkController(NetworkControllerConfig config, GoogCcConfig goog_cc_config); + + GoogCcNetworkController() = delete; + GoogCcNetworkController(const GoogCcNetworkController&) = delete; + GoogCcNetworkController& operator=(const GoogCcNetworkController&) = delete; + ~GoogCcNetworkController() override; // NetworkControllerInterface @@ -137,8 +141,6 @@ class GoogCcNetworkController : public NetworkControllerInterface { bool previously_in_alr_ = false; absl::optional current_data_window_; - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(GoogCcNetworkController); }; } // namespace webrtc diff --git a/modules/congestion_controller/include/receive_side_congestion_controller.h b/modules/congestion_controller/include/receive_side_congestion_controller.h index 6cd8be39a9..034f2e9517 100644 --- a/modules/congestion_controller/include/receive_side_congestion_controller.h +++ b/modules/congestion_controller/include/receive_side_congestion_controller.h @@ -18,7 +18,6 @@ #include "api/transport/network_control.h" #include "modules/include/module.h" #include "modules/remote_bitrate_estimator/remote_estimator_proxy.h" -#include "rtc_base/constructor_magic.h" #include "rtc_base/synchronization/mutex.h" namespace webrtc { @@ -66,6 +65,11 @@ class ReceiveSideCongestionController : public CallStatsObserver, public: WrappingBitrateEstimator(RemoteBitrateObserver* observer, Clock* clock); + WrappingBitrateEstimator() = delete; + WrappingBitrateEstimator(const WrappingBitrateEstimator&) = delete; + WrappingBitrateEstimator& operator=(const WrappingBitrateEstimator&) = + delete; + ~WrappingBitrateEstimator() override; void IncomingPacket(int64_t arrival_time_ms, @@ -96,8 +100,6 @@ class ReceiveSideCongestionController : public CallStatsObserver, bool using_absolute_send_time_; uint32_t packets_since_absolute_send_time_; int min_bitrate_bps_; - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(WrappingBitrateEstimator); }; const FieldTrialBasedConfig field_trial_config_; diff --git a/modules/desktop_capture/win/scoped_gdi_object.h b/modules/desktop_capture/win/scoped_gdi_object.h index 56abe95a9e..d3ac9b9443 100644 --- a/modules/desktop_capture/win/scoped_gdi_object.h +++ b/modules/desktop_capture/win/scoped_gdi_object.h @@ -58,27 +58,29 @@ class ScopedGDIObject { template class DeleteObjectTraits { public: + DeleteObjectTraits() = delete; + DeleteObjectTraits(const DeleteObjectTraits&) = delete; + DeleteObjectTraits& operator=(const DeleteObjectTraits&) = delete; + // Closes the handle. static void Close(T handle) { if (handle) DeleteObject(handle); } - - private: - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(DeleteObjectTraits); }; // The traits class that uses DestroyCursor() to close a handle. class DestroyCursorTraits { public: + DestroyCursorTraits() = delete; + DestroyCursorTraits(const DestroyCursorTraits&) = delete; + DestroyCursorTraits& operator=(const DestroyCursorTraits&) = delete; + // Closes the handle. static void Close(HCURSOR handle) { if (handle) DestroyCursor(handle); } - - private: - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(DestroyCursorTraits); }; typedef ScopedGDIObject > ScopedBitmap; diff --git a/modules/remote_bitrate_estimator/inter_arrival.h b/modules/remote_bitrate_estimator/inter_arrival.h index 1d84970deb..dbc630ff63 100644 --- a/modules/remote_bitrate_estimator/inter_arrival.h +++ b/modules/remote_bitrate_estimator/inter_arrival.h @@ -14,8 +14,6 @@ #include #include -#include "rtc_base/constructor_magic.h" - namespace webrtc { // Helper class to compute the inter-arrival time delta and the size delta @@ -35,6 +33,10 @@ class InterArrival { double timestamp_to_ms_coeff, bool enable_burst_grouping); + InterArrival() = delete; + InterArrival(const InterArrival&) = delete; + InterArrival& operator=(const InterArrival&) = delete; + // This function returns true if a delta was computed, or false if the current // group is still incomplete or if only one group has been completed. // |timestamp| is the timestamp. @@ -87,8 +89,6 @@ class InterArrival { double timestamp_to_ms_coeff_; bool burst_grouping_; int num_consecutive_reordered_packets_; - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(InterArrival); }; } // namespace webrtc diff --git a/modules/remote_bitrate_estimator/remote_bitrate_estimator_abs_send_time.h b/modules/remote_bitrate_estimator/remote_bitrate_estimator_abs_send_time.h index 2423363348..f42a28f8c8 100644 --- a/modules/remote_bitrate_estimator/remote_bitrate_estimator_abs_send_time.h +++ b/modules/remote_bitrate_estimator/remote_bitrate_estimator_abs_send_time.h @@ -27,7 +27,6 @@ #include "modules/remote_bitrate_estimator/overuse_detector.h" #include "modules/remote_bitrate_estimator/overuse_estimator.h" #include "rtc_base/checks.h" -#include "rtc_base/constructor_magic.h" #include "rtc_base/race_checker.h" #include "rtc_base/rate_statistics.h" #include "rtc_base/synchronization/mutex.h" @@ -76,6 +75,13 @@ class RemoteBitrateEstimatorAbsSendTime : public RemoteBitrateEstimator { public: RemoteBitrateEstimatorAbsSendTime(RemoteBitrateObserver* observer, Clock* clock); + + RemoteBitrateEstimatorAbsSendTime() = delete; + RemoteBitrateEstimatorAbsSendTime(const RemoteBitrateEstimatorAbsSendTime&) = + delete; + RemoteBitrateEstimatorAbsSendTime& operator=( + const RemoteBitrateEstimatorAbsSendTime&) = delete; + ~RemoteBitrateEstimatorAbsSendTime() override; void IncomingPacket(int64_t arrival_time_ms, @@ -141,8 +147,6 @@ class RemoteBitrateEstimatorAbsSendTime : public RemoteBitrateEstimator { mutable Mutex mutex_; Ssrcs ssrcs_ RTC_GUARDED_BY(&mutex_); AimdRateControl remote_rate_ RTC_GUARDED_BY(&mutex_); - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(RemoteBitrateEstimatorAbsSendTime); }; } // namespace webrtc diff --git a/modules/remote_bitrate_estimator/remote_bitrate_estimator_single_stream.h b/modules/remote_bitrate_estimator/remote_bitrate_estimator_single_stream.h index 6da67e5a13..9fd2f9fc06 100644 --- a/modules/remote_bitrate_estimator/remote_bitrate_estimator_single_stream.h +++ b/modules/remote_bitrate_estimator/remote_bitrate_estimator_single_stream.h @@ -21,7 +21,6 @@ #include "api/transport/field_trial_based_config.h" #include "modules/remote_bitrate_estimator/aimd_rate_control.h" #include "modules/remote_bitrate_estimator/include/remote_bitrate_estimator.h" -#include "rtc_base/constructor_magic.h" #include "rtc_base/rate_statistics.h" #include "rtc_base/synchronization/mutex.h" #include "rtc_base/thread_annotations.h" @@ -35,6 +34,13 @@ class RemoteBitrateEstimatorSingleStream : public RemoteBitrateEstimator { public: RemoteBitrateEstimatorSingleStream(RemoteBitrateObserver* observer, Clock* clock); + + RemoteBitrateEstimatorSingleStream() = delete; + RemoteBitrateEstimatorSingleStream( + const RemoteBitrateEstimatorSingleStream&) = delete; + RemoteBitrateEstimatorSingleStream& operator=( + const RemoteBitrateEstimatorSingleStream&) = delete; + ~RemoteBitrateEstimatorSingleStream() override; void IncomingPacket(int64_t arrival_time_ms, @@ -74,8 +80,6 @@ class RemoteBitrateEstimatorSingleStream : public RemoteBitrateEstimator { int64_t last_process_time_; int64_t process_interval_ms_ RTC_GUARDED_BY(mutex_); bool uma_recorded_; - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(RemoteBitrateEstimatorSingleStream); }; } // namespace webrtc diff --git a/modules/remote_bitrate_estimator/test/bwe_test_logging.h b/modules/remote_bitrate_estimator/test/bwe_test_logging.h index 5a30da8289..079a7f888d 100644 --- a/modules/remote_bitrate_estimator/test/bwe_test_logging.h +++ b/modules/remote_bitrate_estimator/test/bwe_test_logging.h @@ -263,10 +263,11 @@ class Logging { Context(uint32_t name, int64_t timestamp_ms, bool enabled); Context(const std::string& name, int64_t timestamp_ms, bool enabled); Context(const char* name, int64_t timestamp_ms, bool enabled); - ~Context(); - private: - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(Context); + Context() = delete; + Context(const Context&) = delete; + Context& operator=(const Context&) = delete; + ~Context(); }; static Logging* GetInstance(); diff --git a/modules/rtp_rtcp/source/rtcp_sender.cc b/modules/rtp_rtcp/source/rtcp_sender.cc index 5d2c9a2304..61e6085bb1 100644 --- a/modules/rtp_rtcp/source/rtcp_sender.cc +++ b/modules/rtp_rtcp/source/rtcp_sender.cc @@ -37,7 +37,6 @@ #include "modules/rtp_rtcp/source/time_util.h" #include "modules/rtp_rtcp/source/tmmbr_help.h" #include "rtc_base/checks.h" -#include "rtc_base/constructor_magic.h" #include "rtc_base/logging.h" #include "rtc_base/numerics/safe_conversions.h" #include "rtc_base/trace_event.h" @@ -56,6 +55,10 @@ class PacketContainer : public rtcp::CompoundPacket { PacketContainer(Transport* transport, RtcEventLog* event_log) : transport_(transport), event_log_(event_log) {} + PacketContainer() = delete; + PacketContainer(const PacketContainer&) = delete; + PacketContainer& operator=(const PacketContainer&) = delete; + size_t SendPackets(size_t max_payload_length) { size_t bytes_sent = 0; Build(max_payload_length, [&](rtc::ArrayView packet) { @@ -72,8 +75,6 @@ class PacketContainer : public rtcp::CompoundPacket { private: Transport* transport_; RtcEventLog* const event_log_; - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(PacketContainer); }; // Helper to put several RTCP packets into lower layer datagram RTCP packet. diff --git a/modules/rtp_rtcp/source/rtcp_sender.h b/modules/rtp_rtcp/source/rtcp_sender.h index bcdf15edab..22b2bb7b7c 100644 --- a/modules/rtp_rtcp/source/rtcp_sender.h +++ b/modules/rtp_rtcp/source/rtcp_sender.h @@ -31,7 +31,6 @@ #include "modules/rtp_rtcp/source/rtcp_packet/report_block.h" #include "modules/rtp_rtcp/source/rtcp_packet/tmmb_item.h" #include "modules/rtp_rtcp/source/rtp_rtcp_interface.h" -#include "rtc_base/constructor_magic.h" #include "rtc_base/random.h" #include "rtc_base/synchronization/mutex.h" #include "rtc_base/thread_annotations.h" @@ -65,6 +64,11 @@ class RTCPSender final { }; explicit RTCPSender(const RtpRtcpInterface::Configuration& config); + + RTCPSender() = delete; + RTCPSender(const RTCPSender&) = delete; + RTCPSender& operator=(const RTCPSender&) = delete; + virtual ~RTCPSender(); RtcpMode Status() const RTC_LOCKS_EXCLUDED(mutex_rtcp_sender_); @@ -308,8 +312,6 @@ class RTCPSender final { const RtcpContext&); // Map from RTCPPacketType to builder. std::map builders_; - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(RTCPSender); }; } // namespace webrtc diff --git a/modules/rtp_rtcp/source/rtp_packet_history.h b/modules/rtp_rtcp/source/rtp_packet_history.h index f249116b7a..4a2bf91bd7 100644 --- a/modules/rtp_rtcp/source/rtp_packet_history.h +++ b/modules/rtp_rtcp/source/rtp_packet_history.h @@ -19,7 +19,6 @@ #include "api/function_view.h" #include "modules/rtp_rtcp/include/rtp_rtcp_defines.h" -#include "rtc_base/constructor_magic.h" #include "rtc_base/synchronization/mutex.h" #include "rtc_base/thread_annotations.h" @@ -63,6 +62,11 @@ class RtpPacketHistory { static constexpr int kPacketCullingDelayFactor = 3; RtpPacketHistory(Clock* clock, bool enable_padding_prio); + + RtpPacketHistory() = delete; + RtpPacketHistory(const RtpPacketHistory&) = delete; + RtpPacketHistory& operator=(const RtpPacketHistory&) = delete; + ~RtpPacketHistory(); // Set/get storage mode. Note that setting the state will clear the history, @@ -211,8 +215,6 @@ class RtpPacketHistory { // Objects from |packet_history_| ordered by "most likely to be useful", used // in GetPayloadPaddingPacket(). PacketPrioritySet padding_priority_ RTC_GUARDED_BY(lock_); - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(RtpPacketHistory); }; } // namespace webrtc #endif // MODULES_RTP_RTCP_SOURCE_RTP_PACKET_HISTORY_H_ diff --git a/modules/rtp_rtcp/source/rtp_sender.h b/modules/rtp_rtcp/source/rtp_sender.h index fd1a8da75a..1580259b36 100644 --- a/modules/rtp_rtcp/source/rtp_sender.h +++ b/modules/rtp_rtcp/source/rtp_sender.h @@ -29,7 +29,6 @@ #include "modules/rtp_rtcp/source/rtp_packet_history.h" #include "modules/rtp_rtcp/source/rtp_rtcp_config.h" #include "modules/rtp_rtcp/source/rtp_rtcp_interface.h" -#include "rtc_base/constructor_magic.h" #include "rtc_base/deprecation.h" #include "rtc_base/random.h" #include "rtc_base/rate_statistics.h" @@ -49,6 +48,10 @@ class RTPSender { RtpPacketHistory* packet_history, RtpPacketSender* packet_sender); + RTPSender() = delete; + RTPSender(const RTPSender&) = delete; + RTPSender& operator=(const RTPSender&) = delete; + ~RTPSender(); void SetSendingMediaStatus(bool enabled) RTC_LOCKS_EXCLUDED(send_mutex_); @@ -230,8 +233,6 @@ class RTPSender { bool supports_bwe_extension_ RTC_GUARDED_BY(send_mutex_); RateLimiter* const retransmission_rate_limiter_; - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(RTPSender); }; } // namespace webrtc diff --git a/modules/rtp_rtcp/source/rtp_sender_audio.h b/modules/rtp_rtcp/source/rtp_sender_audio.h index 0ac308dbbe..57b9dd7ce6 100644 --- a/modules/rtp_rtcp/source/rtp_sender_audio.h +++ b/modules/rtp_rtcp/source/rtp_sender_audio.h @@ -22,7 +22,6 @@ #include "modules/rtp_rtcp/source/absolute_capture_time_sender.h" #include "modules/rtp_rtcp/source/dtmf_queue.h" #include "modules/rtp_rtcp/source/rtp_sender.h" -#include "rtc_base/constructor_magic.h" #include "rtc_base/one_time_event.h" #include "rtc_base/synchronization/mutex.h" #include "rtc_base/thread_annotations.h" @@ -33,6 +32,11 @@ namespace webrtc { class RTPSenderAudio { public: RTPSenderAudio(Clock* clock, RTPSender* rtp_sender); + + RTPSenderAudio() = delete; + RTPSenderAudio(const RTPSenderAudio&) = delete; + RTPSenderAudio& operator=(const RTPSenderAudio&) = delete; + ~RTPSenderAudio(); int32_t RegisterAudioPayload(absl::string_view payload_name, @@ -109,8 +113,6 @@ class RTPSenderAudio { const FieldTrialBasedConfig field_trials_; const bool include_capture_clock_offset_; - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(RTPSenderAudio); }; } // namespace webrtc diff --git a/modules/video_coding/codecs/multiplex/multiplex_decoder_adapter.cc b/modules/video_coding/codecs/multiplex/multiplex_decoder_adapter.cc index cd39e72c29..39c14e412c 100644 --- a/modules/video_coding/codecs/multiplex/multiplex_decoder_adapter.cc +++ b/modules/video_coding/codecs/multiplex/multiplex_decoder_adapter.cc @@ -76,23 +76,26 @@ struct MultiplexDecoderAdapter::DecodedImageData { decoded_image_(decoded_image), decode_time_ms_(decode_time_ms), qp_(qp) {} + + DecodedImageData() = delete; + DecodedImageData(const DecodedImageData&) = delete; + DecodedImageData& operator=(const DecodedImageData&) = delete; + const AlphaCodecStream stream_idx_; VideoFrame decoded_image_; const absl::optional decode_time_ms_; const absl::optional qp_; - - private: - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(DecodedImageData); }; struct MultiplexDecoderAdapter::AugmentingData { AugmentingData(std::unique_ptr augmenting_data, uint16_t data_size) : data_(std::move(augmenting_data)), size_(data_size) {} + AugmentingData() = delete; + AugmentingData(const AugmentingData&) = delete; + AugmentingData& operator=(const AugmentingData&) = delete; + std::unique_ptr data_; const uint16_t size_; - - private: - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(AugmentingData); }; MultiplexDecoderAdapter::MultiplexDecoderAdapter( diff --git a/modules/video_coding/frame_buffer2.h b/modules/video_coding/frame_buffer2.h index c88ae891ce..746773d632 100644 --- a/modules/video_coding/frame_buffer2.h +++ b/modules/video_coding/frame_buffer2.h @@ -23,7 +23,6 @@ #include "modules/video_coding/inter_frame_delay.h" #include "modules/video_coding/jitter_estimator.h" #include "modules/video_coding/utility/decoded_frames_history.h" -#include "rtc_base/constructor_magic.h" #include "rtc_base/event.h" #include "rtc_base/experiments/rtt_mult_experiment.h" #include "rtc_base/numerics/sequence_number_util.h" @@ -50,6 +49,10 @@ class FrameBuffer { VCMTiming* timing, VCMReceiveStatisticsCallback* stats_callback); + FrameBuffer() = delete; + FrameBuffer(const FrameBuffer&) = delete; + FrameBuffer& operator=(const FrameBuffer&) = delete; + virtual ~FrameBuffer(); // Insert a frame into the frame buffer. Returns the picture id @@ -188,8 +191,6 @@ class FrameBuffer { // rtt_mult experiment settings. const absl::optional rtt_mult_settings_; - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(FrameBuffer); }; } // namespace video_coding diff --git a/pc/audio_track.h b/pc/audio_track.h index f8ad471852..a0388e8cad 100644 --- a/pc/audio_track.h +++ b/pc/audio_track.h @@ -16,7 +16,6 @@ #include "api/media_stream_interface.h" #include "api/scoped_refptr.h" #include "pc/media_stream_track.h" -#include "rtc_base/constructor_magic.h" #include "rtc_base/thread_checker.h" namespace webrtc { @@ -27,6 +26,11 @@ class AudioTrack : public MediaStreamTrack, // Protected ctor to force use of factory method. AudioTrack(const std::string& label, const rtc::scoped_refptr& source); + + AudioTrack() = delete; + AudioTrack(const AudioTrack&) = delete; + AudioTrack& operator=(const AudioTrack&) = delete; + ~AudioTrack() override; public: @@ -50,7 +54,6 @@ class AudioTrack : public MediaStreamTrack, private: const rtc::scoped_refptr audio_source_; rtc::ThreadChecker thread_checker_; - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(AudioTrack); }; } // namespace webrtc diff --git a/pc/ice_transport.h b/pc/ice_transport.h index 69b69e41d8..c1529de6b7 100644 --- a/pc/ice_transport.h +++ b/pc/ice_transport.h @@ -12,7 +12,6 @@ #define PC_ICE_TRANSPORT_H_ #include "api/ice_transport_interface.h" -#include "rtc_base/constructor_magic.h" #include "rtc_base/thread.h" #include "rtc_base/thread_checker.h" @@ -29,6 +28,10 @@ class IceTransportWithPointer : public IceTransportInterface { RTC_DCHECK(internal_); } + IceTransportWithPointer() = delete; + IceTransportWithPointer(const IceTransportWithPointer&) = delete; + IceTransportWithPointer& operator=(const IceTransportWithPointer&) = delete; + cricket::IceTransportInternal* internal() override; // This call will ensure that the pointer passed at construction is // no longer in use by this object. Later calls to internal() will return @@ -39,7 +42,6 @@ class IceTransportWithPointer : public IceTransportInterface { ~IceTransportWithPointer() override; private: - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(IceTransportWithPointer); const rtc::Thread* creator_thread_; cricket::IceTransportInternal* internal_ RTC_GUARDED_BY(creator_thread_); }; diff --git a/pc/remote_audio_source.cc b/pc/remote_audio_source.cc index 18a4ed25c8..8ae0612541 100644 --- a/pc/remote_audio_source.cc +++ b/pc/remote_audio_source.cc @@ -18,7 +18,6 @@ #include "absl/algorithm/container.h" #include "api/scoped_refptr.h" #include "rtc_base/checks.h" -#include "rtc_base/constructor_magic.h" #include "rtc_base/location.h" #include "rtc_base/logging.h" #include "rtc_base/numerics/safe_conversions.h" @@ -36,6 +35,11 @@ class RemoteAudioSource::AudioDataProxy : public AudioSinkInterface { explicit AudioDataProxy(RemoteAudioSource* source) : source_(source) { RTC_DCHECK(source); } + + AudioDataProxy() = delete; + AudioDataProxy(const AudioDataProxy&) = delete; + AudioDataProxy& operator=(const AudioDataProxy&) = delete; + ~AudioDataProxy() override { source_->OnAudioChannelGone(); } // AudioSinkInterface implementation. @@ -45,8 +49,6 @@ class RemoteAudioSource::AudioDataProxy : public AudioSinkInterface { private: const rtc::scoped_refptr source_; - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(AudioDataProxy); }; RemoteAudioSource::RemoteAudioSource(rtc::Thread* worker_thread) diff --git a/rtc_base/BUILD.gn b/rtc_base/BUILD.gn index e3b4581385..e15206c75a 100644 --- a/rtc_base/BUILD.gn +++ b/rtc_base/BUILD.gn @@ -599,7 +599,6 @@ rtc_library("rtc_numerics") { ] deps = [ ":checks", - ":macromagic", ":rtc_base_approved", ] absl_deps = [ "//third_party/abseil-cpp/absl/types:optional" ] @@ -1066,7 +1065,6 @@ rtc_library("testclient") { deps = [ ":criticalsection", ":gunit_helpers", - ":macromagic", ":rtc_base", ":rtc_base_tests_utils", ":timeutils", @@ -1150,7 +1148,6 @@ rtc_library("task_queue_for_test") { ] deps = [ ":checks", - ":macromagic", ":rtc_base_approved", ":rtc_event", ":rtc_task_queue", diff --git a/rtc_base/constructor_magic.h b/rtc_base/constructor_magic.h index e63c2ff628..8d12a7b135 100644 --- a/rtc_base/constructor_magic.h +++ b/rtc_base/constructor_magic.h @@ -11,24 +11,10 @@ #ifndef RTC_BASE_CONSTRUCTOR_MAGIC_H_ #define RTC_BASE_CONSTRUCTOR_MAGIC_H_ -// Put this in the declarations for a class to be unassignable. -#define RTC_DISALLOW_ASSIGN(TypeName) \ - TypeName& operator=(const TypeName&) = delete - // A macro to disallow the copy constructor and operator= functions. This should // be used in the declarations for a class. #define RTC_DISALLOW_COPY_AND_ASSIGN(TypeName) \ TypeName(const TypeName&) = delete; \ - RTC_DISALLOW_ASSIGN(TypeName) - -// A macro to disallow all the implicit constructors, namely the default -// constructor, copy constructor and operator= functions. -// -// This should be used in the declarations for a class that wants to prevent -// anyone from instantiating it. This is especially useful for classes -// containing only static methods. -#define RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(TypeName) \ - TypeName() = delete; \ - RTC_DISALLOW_COPY_AND_ASSIGN(TypeName) + TypeName& operator=(const TypeName&) = delete #endif // RTC_BASE_CONSTRUCTOR_MAGIC_H_ diff --git a/rtc_base/deprecated/signal_thread.h b/rtc_base/deprecated/signal_thread.h index 65f96bcd6d..10805ad456 100644 --- a/rtc_base/deprecated/signal_thread.h +++ b/rtc_base/deprecated/signal_thread.h @@ -110,14 +110,17 @@ class DEPRECATED_SignalThread : public sigslot::has_slots<>, class Worker : public Thread { public: explicit Worker(DEPRECATED_SignalThread* parent); + + Worker() = delete; + Worker(const Worker&) = delete; + Worker& operator=(const Worker&) = delete; + ~Worker() override; void Run() override; bool IsProcessingMessagesForTesting() override; private: DEPRECATED_SignalThread* parent_; - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(Worker); }; class RTC_SCOPED_LOCKABLE EnterExit { @@ -131,6 +134,11 @@ class DEPRECATED_SignalThread : public sigslot::has_slots<>, RTC_DCHECK_NE(0, t_->refcount_); ++t_->refcount_; } + + EnterExit() = delete; + EnterExit(const EnterExit&) = delete; + EnterExit& operator=(const EnterExit&) = delete; + ~EnterExit() RTC_UNLOCK_FUNCTION() { bool d = (0 == --t_->refcount_); t_->cs_.Leave(); @@ -140,8 +148,6 @@ class DEPRECATED_SignalThread : public sigslot::has_slots<>, private: DEPRECATED_SignalThread* t_; - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(EnterExit); }; void Run(); diff --git a/rtc_base/random.h b/rtc_base/random.h index 93241a3e97..0e2d103cb6 100644 --- a/rtc_base/random.h +++ b/rtc_base/random.h @@ -16,7 +16,6 @@ #include #include "rtc_base/checks.h" -#include "rtc_base/constructor_magic.h" namespace webrtc { @@ -35,6 +34,10 @@ class Random { // See also discussion here: https://codereview.webrtc.org/1623543002/ explicit Random(uint64_t seed); + Random() = delete; + Random(const Random&) = delete; + Random& operator=(const Random&) = delete; + // Return pseudo-random integer of the specified type. // We need to limit the size to 32 bits to keep the output close to uniform. template @@ -73,8 +76,6 @@ class Random { } uint64_t state_; - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(Random); }; // Return pseudo-random number in the interval [0.0, 1.0). diff --git a/rtc_base/rate_limiter.h b/rtc_base/rate_limiter.h index 051ccf6aa6..9bbe21f9ca 100644 --- a/rtc_base/rate_limiter.h +++ b/rtc_base/rate_limiter.h @@ -14,7 +14,6 @@ #include #include -#include "rtc_base/constructor_magic.h" #include "rtc_base/rate_statistics.h" #include "rtc_base/synchronization/mutex.h" #include "rtc_base/thread_annotations.h" @@ -29,6 +28,11 @@ class Clock; class RateLimiter { public: RateLimiter(Clock* clock, int64_t max_window_ms); + + RateLimiter() = delete; + RateLimiter(const RateLimiter&) = delete; + RateLimiter& operator=(const RateLimiter&) = delete; + ~RateLimiter(); // Try to use rate to send bytes. Returns true on success and if so updates @@ -49,8 +53,6 @@ class RateLimiter { RateStatistics current_rate_ RTC_GUARDED_BY(lock_); int64_t window_size_ms_ RTC_GUARDED_BY(lock_); uint32_t max_rate_bps_ RTC_GUARDED_BY(lock_); - - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(RateLimiter); }; } // namespace webrtc diff --git a/rtc_base/weak_ptr.h b/rtc_base/weak_ptr.h index 3e63a7587d..8b2ba099cb 100644 --- a/rtc_base/weak_ptr.h +++ b/rtc_base/weak_ptr.h @@ -241,6 +241,10 @@ class WeakPtrFactory { public: explicit WeakPtrFactory(T* ptr) : ptr_(ptr) {} + WeakPtrFactory() = delete; + WeakPtrFactory(const WeakPtrFactory&) = delete; + WeakPtrFactory& operator=(const WeakPtrFactory&) = delete; + ~WeakPtrFactory() { ptr_ = nullptr; } WeakPtr GetWeakPtr() { @@ -263,7 +267,6 @@ class WeakPtrFactory { private: internal::WeakReferenceOwner weak_reference_owner_; T* ptr_; - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(WeakPtrFactory); }; } // namespace rtc diff --git a/rtc_tools/rtp_generator/rtp_generator.h b/rtc_tools/rtp_generator/rtp_generator.h index 6248c6a636..a317bf7278 100644 --- a/rtc_tools/rtp_generator/rtp_generator.h +++ b/rtc_tools/rtp_generator/rtp_generator.h @@ -27,7 +27,6 @@ #include "call/rtp_config.h" #include "call/video_send_stream.h" #include "media/engine/webrtc_video_engine.h" -#include "rtc_base/constructor_magic.h" #include "test/frame_generator_capturer.h" #include "test/rtp_file_reader.h" #include "test/rtp_file_writer.h" @@ -79,6 +78,11 @@ class RtpGenerator final : public webrtc::Transport { public: // Construct a new RtpGenerator using the specified options. explicit RtpGenerator(const RtpGeneratorOptions& options); + + RtpGenerator() = delete; + RtpGenerator(const RtpGenerator&) = delete; + RtpGenerator& operator=(const RtpGenerator&) = delete; + // Cleans up the VideoSendStream. ~RtpGenerator() override; // Generates an rtp_dump that is written out to @@ -113,9 +117,6 @@ class RtpGenerator final : public webrtc::Transport { std::vector durations_ms_; uint32_t start_ms_ = 0; std::unique_ptr task_queue_; - - // This object cannot be copied. - RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(RtpGenerator); }; } // namespace webrtc diff --git a/video/BUILD.gn b/video/BUILD.gn index 96d0faa769..b833022f73 100644 --- a/video/BUILD.gn +++ b/video/BUILD.gn @@ -241,7 +241,6 @@ rtc_library("video_stream_encoder_impl") { "../rtc_base:checks", "../rtc_base:criticalsection", "../rtc_base:logging", - "../rtc_base:macromagic", "../rtc_base:rtc_base_approved", "../rtc_base:rtc_event", "../rtc_base:rtc_numerics", diff --git a/video/adaptation/BUILD.gn b/video/adaptation/BUILD.gn index eab01cd290..2a60eadc5e 100644 --- a/video/adaptation/BUILD.gn +++ b/video/adaptation/BUILD.gn @@ -42,7 +42,6 @@ rtc_library("video_adaptation") { "../../modules/video_coding:video_coding_utility", "../../rtc_base:checks", "../../rtc_base:logging", - "../../rtc_base:macromagic", "../../rtc_base:rtc_base_approved", "../../rtc_base:rtc_event", "../../rtc_base:rtc_numerics",