Migrate absl::optional to std::optional
Bug: webrtc:342905193
No-Try: True
Change-Id: Icc968be43b8830038ea9a1f5f604307220457807
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/361021
Auto-Submit: Florent Castelli <orphis@webrtc.org>
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Commit-Queue: Florent Castelli <orphis@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42911}
diff --git a/api/audio_codecs/audio_decoder.h b/api/audio_codecs/audio_decoder.h
index 4113874..21d6056 100644
--- a/api/audio_codecs/audio_decoder.h
+++ b/api/audio_codecs/audio_decoder.h
@@ -15,9 +15,9 @@
#include <stdint.h>
#include <memory>
+#include <optional>
#include <vector>
-#include "absl/types/optional.h"
#include "api/array_view.h"
#include "rtc_base/buffer.h"
@@ -57,11 +57,11 @@
// Decodes this frame of audio and writes the result in `decoded`.
// `decoded` must be large enough to store as many samples as indicated by a
- // call to Duration() . On success, returns an absl::optional containing the
+ // call to Duration() . On success, returns an std::optional containing the
// total number of samples across all channels, as well as whether the
// decoder produced comfort noise or speech. On failure, returns an empty
- // absl::optional. Decode may be called at most once per frame object.
- virtual absl::optional<DecodeResult> Decode(
+ // std::optional. Decode may be called at most once per frame object.
+ virtual std::optional<DecodeResult> Decode(
rtc::ArrayView<int16_t> decoded) const = 0;
};