educe/trait_handlers/default/
panic.rs1use proc_macro2::Span;
2
3#[inline]
4pub(crate) fn multiple_default_fields(span: Span) -> syn::Error {
5 syn::Error::new(span, "multiple default fields are set")
6}
7
8#[inline]
9pub(crate) fn no_default_field(span: Span) -> syn::Error {
10 syn::Error::new(span, "there is no field set as default")
11}
12
13#[inline]
14pub(crate) fn multiple_default_variants(span: Span) -> syn::Error {
15 syn::Error::new(span, "multiple default variants are set")
16}
17
18#[inline]
19pub(crate) fn no_default_variant(span: Span) -> syn::Error {
20 syn::Error::new(span, "there is no variant set as default")
21}