mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer-rs.git
synced 2025-02-13 01:25:30 +00:00
gstreamer: Require Send
and not Sync
for the values of an Array
/ List
`Sync` is more than required here: only sending of the values to another thread is required.
This commit is contained in:
parent
24a2bb78a6
commit
5b24acb9c0
1 changed files with 2 additions and 2 deletions
|
@ -653,7 +653,7 @@ unsafe impl Send for Array {}
|
||||||
unsafe impl Sync for Array {}
|
unsafe impl Sync for Array {}
|
||||||
|
|
||||||
impl Array {
|
impl Array {
|
||||||
pub fn new(values: impl IntoIterator<Item = impl ToSendValue + Sync>) -> Self {
|
pub fn new(values: impl IntoIterator<Item = impl ToSendValue + Send>) -> Self {
|
||||||
assert_initialized_main_thread!();
|
assert_initialized_main_thread!();
|
||||||
|
|
||||||
Self(values.into_iter().map(|v| v.to_send_value()).collect())
|
Self(values.into_iter().map(|v| v.to_send_value()).collect())
|
||||||
|
@ -823,7 +823,7 @@ unsafe impl Send for List {}
|
||||||
unsafe impl Sync for List {}
|
unsafe impl Sync for List {}
|
||||||
|
|
||||||
impl List {
|
impl List {
|
||||||
pub fn new(values: impl IntoIterator<Item = impl ToSendValue + Sync>) -> Self {
|
pub fn new(values: impl IntoIterator<Item = impl ToSendValue + Send>) -> Self {
|
||||||
assert_initialized_main_thread!();
|
assert_initialized_main_thread!();
|
||||||
|
|
||||||
Self(values.into_iter().map(|v| v.to_send_value()).collect())
|
Self(values.into_iter().map(|v| v.to_send_value()).collect())
|
||||||
|
|
Loading…
Reference in a new issue