Skip to main content

mujoco_rs_derive/
lib.rs

1//! Procedural macros for the [`mujoco-rs`](https://crates.io/crates/mujoco-rs) crate.
2
3extern crate proc_macro;
4
5mod three_way_merge;
6
7use proc_macro::TokenStream;
8
9/// Derives `ThreeWayMerge` for a struct with named fields.
10///
11/// This macro is an implementation detail of `mujoco-rs` and is not intended
12/// for direct use outside of that crate.
13#[proc_macro_derive(ThreeWayMerge)]
14pub fn derive_three_way_merge(input: TokenStream) -> TokenStream {
15    three_way_merge::derive(input)
16}