From c00270aa7a2db89d32c086e6b36351105b9913c9 Mon Sep 17 00:00:00 2001 From: Robin Mueller Date: Sun, 27 Nov 2022 15:48:21 +0100 Subject: [PATCH] add macro crate --- Cargo.lock | 9 +++++++++ Cargo.toml | 3 ++- satrs-macros/Cargo.toml | 16 ++++++++++++++++ satrs-macros/src/lib.rs | 0 4 files changed, 27 insertions(+), 1 deletion(-) create mode 100644 satrs-macros/Cargo.toml create mode 100644 satrs-macros/src/lib.rs diff --git a/Cargo.lock b/Cargo.lock index bfb4844..a210b52 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -627,6 +627,15 @@ dependencies = [ "zerocopy", ] +[[package]] +name = "satrs-macro" +version = "0.1.0" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + [[package]] name = "scopeguard" version = "1.1.0" diff --git a/Cargo.toml b/Cargo.toml index 4334157..54193d5 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -2,6 +2,7 @@ members = [ "satrs-core", + "satrs-macros", + "satrs-example", "spacepackets", - "satrs-example" ] diff --git a/satrs-macros/Cargo.toml b/satrs-macros/Cargo.toml new file mode 100644 index 0000000..7f56423 --- /dev/null +++ b/satrs-macros/Cargo.toml @@ -0,0 +1,16 @@ +[package] +name = "satrs-macro" +version = "0.1.0" +edition = "2021" + +# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html +[lib] +proc-macro = true + +[dependencies] +quote = "1.0" +proc-macro2 = "1.0" + +[dependencies.syn] +version = "1.0" +features = ["extra-traits"] diff --git a/satrs-macros/src/lib.rs b/satrs-macros/src/lib.rs new file mode 100644 index 0000000..e69de29