File: 03-object-no-auto-send-sync.stderr

package info (click to toggle)
rust-glib 0.21.2-1
  • links: PTS, VCS
  • area: main
  • in suites:
  • size: 2,452 kB
  • sloc: makefile: 18
file content (41 lines) | stat: -rw-r--r-- 1,811 bytes parent folder | download | duplicates (5)
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
error[E0277]: `*mut c_void` cannot be sent between threads safely
 --> tests/subclass_compiletest/03-object-no-auto-send-sync.rs:5:11
  |
5 |     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 `Object`
 --> src/object.rs
  |
  |     pub Object, *mut std::os::raw::c_void, (), gobject_ffi::GObject, @ffi_class gobject_ffi::GObjectClass, @type_ gobject_ffi::g_object_g...
  |         ^^^^^^
note: required by a bound in `main::check`
 --> tests/subclass_compiletest/03-object-no-auto-send-sync.rs:2:17
  |
2 |     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/03-object-no-auto-send-sync.rs:5:11
  |
5 |     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 `Object`
 --> src/object.rs
  |
  |     pub Object, *mut std::os::raw::c_void, (), gobject_ffi::GObject, @ffi_class gobject_ffi::GObjectClass, @type_ gobject_ffi::g_object_g...
  |         ^^^^^^
note: required by a bound in `main::check`
 --> tests/subclass_compiletest/03-object-no-auto-send-sync.rs:2:17
  |
2 |     fn check<T: Send + Sync>(_obj: &T) {}
  |                 ^^^^ required by this bound in `check`