Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Shm mutation example #861

Merged
merged 7 commits into from
Dec 18, 2024

Conversation

yellowhatter
Copy link
Contributor

Shm mutation example + some API additions for mutable accesses

Few API improvements
Add missing mutable accessor 'z_sample_payload_mut'
@yellowhatter yellowhatter added enhancement New feature or request release Part of the next release api sync Synchronize API with other bindings api fix Problem in the API labels Dec 17, 2024
@yellowhatter yellowhatter self-assigned this Dec 17, 2024
@@ -60,6 +60,17 @@ pub extern "C" fn z_reply_err_payload(this_: &z_loaned_reply_err_t) -> &z_loaned
this_.as_rust_type_ref().payload().as_loaned_c_type_ref()
}

/// Returns mutable reply error payload.
#[no_mangle]
pub extern "C" fn z_reply_err_payload_mut(
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is no way to get mutable err or mutable sample from the reply, so this method is useless for now.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Then we should add this. SHM buffer may reside literally everywhere where ZBytes is

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

added

@DenisBiryukov91
Copy link
Contributor

Could you also add docs for all new functions.

Conflicts:
	Cargo.lock
	build-resources/opaque-types/Cargo.lock
@yellowhatter yellowhatter marked this pull request as ready for review December 18, 2024 10:46
@yellowhatter
Copy link
Contributor Author

Could you also add docs for all new functions.

done

@yellowhatter yellowhatter merged commit 2f38959 into eclipse-zenoh:main Dec 18, 2024
18 of 20 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api fix Problem in the API api sync Synchronize API with other bindings enhancement New feature or request release Part of the next release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants