From e3566620fac3eea67df11a9cff0021d185d7faf8 Mon Sep 17 00:00:00 2001 From: YUCLing Date: Sun, 30 Apr 2023 20:26:00 +0800 Subject: [PATCH] fix: scs-rs is renamed to scs-sdk-rs --- proc_macros/README.md | 2 ++ proc_macros/src/lib.rs | 6 +++--- 2 files changed, 5 insertions(+), 3 deletions(-) create mode 100644 proc_macros/README.md diff --git a/proc_macros/README.md b/proc_macros/README.md new file mode 100644 index 0000000..8f28ea2 --- /dev/null +++ b/proc_macros/README.md @@ -0,0 +1,2 @@ +# Procedural macros for scs-sdk-rs +This crate contains proc macros for [scs-sdk-rs](https://crates.io/crates/scs-sdk-rs) \ No newline at end of file diff --git a/proc_macros/src/lib.rs b/proc_macros/src/lib.rs index 401ecb8..4f759a9 100644 --- a/proc_macros/src/lib.rs +++ b/proc_macros/src/lib.rs @@ -21,7 +21,7 @@ pub fn scs_api(args: TokenStream, input: TokenStream) -> TokenStream { input.sig.abi = syn::parse_str("extern \"C\"").unwrap(); if api_type == "result" { - input.sig.output = syn::parse_str("-> scs_rs::scs_result_t").unwrap(); + input.sig.output = syn::parse_str("-> scs_sdk_rs::scs_result_t").unwrap(); } TokenStream::from(quote!(#input)) @@ -33,9 +33,9 @@ pub fn scs_telemetry_init(_args: TokenStream, input: TokenStream) -> TokenStream let mut input = parse_macro_input!(input as ItemFn); let mut punc = Punctuated::new(); - punc.push_value(syn::parse_str::("version: scs_rs::scs_u32_t").unwrap()); + punc.push_value(syn::parse_str::("version: scs_sdk_rs::scs_u32_t").unwrap()); punc.push_punct(syn::parse_str::(",").unwrap()); - punc.push_value(syn::parse_str("params: *const scs_rs::scs_telemetry_init_params_t").unwrap()); + punc.push_value(syn::parse_str("params: *const scs_sdk_rs::scs_telemetry_init_params_t").unwrap()); input.sig.inputs = punc; input.sig.ident = syn::parse_str("scs_telemetry_init").unwrap();