]> git.proxmox.com Git - perlmod.git/commitdiff
document errno and serializ_error in the #[export] doc
authorWolfgang Bumiller <w.bumiller@proxmox.com>
Tue, 28 May 2024 09:08:13 +0000 (11:08 +0200)
committerWolfgang Bumiller <w.bumiller@proxmox.com>
Tue, 28 May 2024 09:08:13 +0000 (11:08 +0200)
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
perlmod/src/lib.rs

index a1b9e74faa2f29e057b86bf4bf77a4e9c2141fec..e4eac8f3efb29dcd42ff87cbd532d4c82bba7eae 100644 (file)
@@ -87,6 +87,11 @@ pub use perlmod_macro::package;
 /// * `name`: the name the function should be using in perl. This only makes sense with the
 ///   `#[package]` macro, as otherwise the user is responsible for loading the function via perl's
 ///   `DynaLoader` on their own.
+/// * `errno`: copy the value set via [`set_errno`](crate::error::set_errno) to libc's `errno`
+///   location before returning to perl (after all side effects such as destructors) have run, in
+///   order to allow setting perl's `$!` variable.
+/// * `serialize_error`: Instead of stringifying the `Err` part of a `Result` via `Display`,
+///   serialize it into a structured value.
 ///
 /// Additionally, function parameters can also use the following attributes:
 ///