From f8c4b8f33d3da5a943bfa29a14abdb3484122083 Mon Sep 17 00:00:00 2001 From: Michael Williamson Date: Fri, 31 Jul 2026 13:57:06 +0100 Subject: Add Clone and Copy to generated Rust types --- examples/08-native-type/output/rust/src/gen/point.rs | 2 +- examples/08-native-type/output/rust/src/point.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'examples/08-native-type') diff --git a/examples/08-native-type/output/rust/src/gen/point.rs b/examples/08-native-type/output/rust/src/gen/point.rs index d383b15..8561605 100644 --- a/examples/08-native-type/output/rust/src/gen/point.rs +++ b/examples/08-native-type/output/rust/src/gen/point.rs @@ -1,7 +1,7 @@ // Generated by hobgoblin. /// A straight line from one point to another. -#[derive(Debug, Hash, PartialEq)] +#[derive(Clone, Debug, Hash, PartialEq)] pub struct Line { pub start: crate::point::Point, pub end: crate::point::Point, diff --git a/examples/08-native-type/output/rust/src/point.rs b/examples/08-native-type/output/rust/src/point.rs index c5b73d7..3c763e2 100644 --- a/examples/08-native-type/output/rust/src/point.rs +++ b/examples/08-native-type/output/rust/src/point.rs @@ -1,4 +1,4 @@ include!("gen/point.rs"); -#[derive(Debug, Hash, PartialEq)] +#[derive(Clone, Debug, Hash, PartialEq)] pub struct Point(pub i32, pub i32); -- cgit v1.2.3