Skip to main content

Module codegen_csharp

Module codegen_csharp 

Source
Expand description

The C# side of the JSON bridge: a wrapper with the original classes and signatures under <namespace>.Rust, each method calling the Rust library through P/Invoke, and the driver that records the original and diffs the wrapper.

Functions§

driver
native_class
package_references
The project’s unconditional <PackageReference> tags, without build-only tooling (Source Link, reference assemblies, analyzers, versioning): references under a Condition target other frameworks than the driver’s.
project
The driver’s project: the owning project’s sources, its package references and settings.
qualified
(namespace, class, method) of an exported static method, from its prototype (Acme.Text.Slug.Slugify(string text)).
rust_namespace
The namespace of the wrapper classes for an original namespace.
targets
{ name: { original: "Ns.Class", rust: "Ns.Rust.Class", method } } for the driver.
wrapper
wrapper_path