File: 06-no-auto-send-sync-with-non-send-sync-ffi-parent.stderr

package info (click to toggle)
rust-glib 0.21.2-1
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 2,452 kB
  • sloc: makefile: 18
file content (53 lines) | stat: -rw-r--r-- 2,887 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
error[E0277]: `*mut c_void` cannot be sent between threads safely
  --> tests/subclass_compiletest/06-no-auto-send-sync-with-non-send-sync-ffi-parent.rs:54:11
   |
54 |     check(&obj);
   |     ----- ^^^^ `*mut c_void` cannot be sent between threads safely
   |     |
   |     required by a bound introduced by this call
   |
   = help: the trait `Send` is not implemented for `*mut c_void`
   = note: required for `TypedObjectRef<*mut c_void, ()>` to implement `Send`
note: required because it appears within the type `InitiallyUnowned`
  --> tests/subclass_compiletest/06-no-auto-send-sync-with-non-send-sync-ffi-parent.rs:3:16
   |
3  |     pub struct InitiallyUnowned(Object<glib::gobject_ffi::GInitiallyUnowned, glib::gobject_ffi::GInitiallyUnownedClass>);
   |                ^^^^^^^^^^^^^^^^
   = note: required for `TypedObjectRef<imp_object::TestObject, InitiallyUnowned>` to implement `Send`
note: required because it appears within the type `TestObject`
  --> tests/subclass_compiletest/06-no-auto-send-sync-with-non-send-sync-ffi-parent.rs:41:16
   |
41 |     pub struct TestObject(ObjectSubclass<imp_object::TestObject>) @extends InitiallyUnowned;
   |                ^^^^^^^^^^
note: required by a bound in `main::check`
  --> tests/subclass_compiletest/06-no-auto-send-sync-with-non-send-sync-ffi-parent.rs:51:17
   |
51 |     fn check<T: Send + Sync>(_obj: &T) {}
   |                 ^^^^ required by this bound in `check`

error[E0277]: `*mut c_void` cannot be shared between threads safely
  --> tests/subclass_compiletest/06-no-auto-send-sync-with-non-send-sync-ffi-parent.rs:54:11
   |
54 |     check(&obj);
   |     ----- ^^^^ `*mut c_void` cannot be shared between threads safely
   |     |
   |     required by a bound introduced by this call
   |
   = help: the trait `Sync` is not implemented for `*mut c_void`
   = note: required for `TypedObjectRef<*mut c_void, ()>` to implement `Send`
note: required because it appears within the type `InitiallyUnowned`
  --> tests/subclass_compiletest/06-no-auto-send-sync-with-non-send-sync-ffi-parent.rs:3:16
   |
3  |     pub struct InitiallyUnowned(Object<glib::gobject_ffi::GInitiallyUnowned, glib::gobject_ffi::GInitiallyUnownedClass>);
   |                ^^^^^^^^^^^^^^^^
   = note: required for `TypedObjectRef<imp_object::TestObject, InitiallyUnowned>` to implement `Send`
note: required because it appears within the type `TestObject`
  --> tests/subclass_compiletest/06-no-auto-send-sync-with-non-send-sync-ffi-parent.rs:41:16
   |
41 |     pub struct TestObject(ObjectSubclass<imp_object::TestObject>) @extends InitiallyUnowned;
   |                ^^^^^^^^^^
note: required by a bound in `main::check`
  --> tests/subclass_compiletest/06-no-auto-send-sync-with-non-send-sync-ffi-parent.rs:51:17
   |
51 |     fn check<T: Send + Sync>(_obj: &T) {}
   |                 ^^^^ required by this bound in `check`