mirror of
https://github.com/bytedream/serde-inline-default.git
synced 2026-11-04 15:12:09 +01:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
6eea08da2d | ||
|
|
473210c388 |
No files matched your search
+3
-10
@@ -1,6 +1,6 @@
|
|||||||
[package]
|
[package]
|
||||||
name = "serde-inline-default"
|
name = "serde-inline-default"
|
||||||
version = "1.0.2"
|
version = "1.0.3"
|
||||||
authors = ["bytedream"]
|
authors = ["bytedream"]
|
||||||
edition = "2021"
|
edition = "2021"
|
||||||
rust-version = "1.71.0"
|
rust-version = "1.71.0"
|
||||||
@@ -10,18 +10,11 @@ repository = "https://github.com/bytedream/serde-inline-default"
|
|||||||
license = "MIT OR Apache-2.0"
|
license = "MIT OR Apache-2.0"
|
||||||
keywords = ["serde", "serialization"]
|
keywords = ["serde", "serialization"]
|
||||||
categories = ["encoding"]
|
categories = ["encoding"]
|
||||||
include = [
|
include = ["/Cargo.toml", "/LICENSE-APACHE", "/LICENSE-MIT", "/README.md", "/src/**", "/tests/**"]
|
||||||
"/Cargo.toml",
|
|
||||||
"/LICENSE-APACHE",
|
|
||||||
"/LICENSE-MIT",
|
|
||||||
"/README.md",
|
|
||||||
"/src/**",
|
|
||||||
"/tests/**"
|
|
||||||
]
|
|
||||||
|
|
||||||
[lib]
|
[lib]
|
||||||
proc-macro = true
|
|
||||||
doctest = false
|
doctest = false
|
||||||
|
proc-macro = true
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
proc-macro2 = "1.0"
|
proc-macro2 = "1.0"
|
||||||
|
|||||||
@@ -73,6 +73,7 @@ pub(crate) fn check_field_for_default_expr(
|
|||||||
let default_fn_expr = quote! {
|
let default_fn_expr = quote! {
|
||||||
#[doc(hidden)]
|
#[doc(hidden)]
|
||||||
#[allow(non_snake_case)]
|
#[allow(non_snake_case)]
|
||||||
|
#[inline]
|
||||||
#( #cfg_attrs )*
|
#( #cfg_attrs )*
|
||||||
fn #default_fn_ident () -> #return_type {
|
fn #default_fn_ident () -> #return_type {
|
||||||
#default_expr
|
#default_expr
|
||||||
|
|||||||
Reference in new issue
Block a user