File tree Expand file tree Collapse file tree 1 file changed +17
-12
lines changed
rosidl_generator_rs/resource Expand file tree Collapse file tree 1 file changed +17
-12
lines changed Original file line number Diff line number Diff line change @@ -44,18 +44,23 @@ TEMPLATE(
44
44
type_name = action_spec .namespaced_type .name
45
45
}@
46
46
47
- // Corresponds to @ (package_name)__@ (subfolder)__@ (type_name)
48
- pub struct @ (type_name);
49
-
50
- impl rosidl_runtime_rs :: Action for @ (type_name) {
51
- type Goal = crate :: @ (subfolder):: rmw :: @ (type_name)_Goal;
52
- type Result = crate :: @ (subfolder):: rmw :: @ (type_name)_Result;
53
- type Feedback = crate :: @ (subfolder):: rmw :: @ (type_name)_Feedback;
54
-
55
- fn get_type_support () -> * const std :: os :: raw :: c_void {
56
- // SAFETY : No preconditions for this function .
57
- unsafe { rosidl_typesupport_c__get_action_type_support_handle__@ (package_name)__@ (subfolder)__@ (type_name)() }
58
- }
47
+ # [link(name = "@(package_name)__rosidl_typesupport_c")]
48
+ extern " C" {
49
+ fn rosidl_typesupport_c__get_action_type_support_handle__@ (package_name)__@ (subfolder)__@ (type_name)() -> * const std :: os :: raw :: c_void ;
50
+ }
51
+
52
+ // Corresponds to @ (package_name)__@ (subfolder)__@ (type_name)
53
+ pub struct @ (type_name);
54
+
55
+ impl rosidl_runtime_rs :: Action for @ (type_name) {
56
+ type Goal = crate :: @ (subfolder):: rmw :: @ (type_name)_Goal;
57
+ type Result = crate :: @ (subfolder):: rmw :: @ (type_name)_Result;
58
+ type Feedback = crate :: @ (subfolder):: rmw :: @ (type_name)_Feedback;
59
+
60
+ fn get_type_support () -> * const std :: os :: raw :: c_void {
61
+ // SAFETY : No preconditions for this function .
62
+ unsafe { rosidl_typesupport_c__get_action_type_support_handle__@ (package_name)__@ (subfolder)__@ (type_name)() }
59
63
}
64
+ }
60
65
61
66
@ [end for ]
You can’t perform that action at this time.
0 commit comments