xso-proc: avoid an ambiguous_associated_items error
rustc forbids cases where an enum variant and an associated type of a trait conflict for a while now [1]. We must thus avoid referring to associated items on types we do not control in the macros. There was only one case I found, and it was in the TryFrom implementation, and could be easily resolved by explicitly spelling out Self::Error. [1]: https://github.com/rust-lang/rust/issues/57644
This commit is contained in:
parent
dae6e49cce
commit
8d8a19380a
1 changed files with 1 additions and 1 deletions
|
|
@ -95,7 +95,7 @@ fn from_xml_impl(input: Item) -> Result<TokenStream> {
|
|||
impl ::core::convert::TryFrom<::xso::exports::minidom::Element> for #ident {
|
||||
type Error = ::xso::error::FromElementError;
|
||||
|
||||
fn try_from(other: ::xso::exports::minidom::Element) -> ::core::result::Result<Self, Self::Error> {
|
||||
fn try_from(other: ::xso::exports::minidom::Element) -> ::core::result::Result<Self, ::xso::error::FromElementError> {
|
||||
::xso::try_from_element(other)
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue