X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=blobdiff_plain;f=lightning%2Fsrc%2Foffers%2Fparse.rs;h=42ed2e002d1f29b60169c86954f39cece3101647;hb=ba342de241f0b5e968d6ad0106e5690e7c9c68bc;hp=6afd4d68fef385bb5b6b77b8375891e53878f6e7;hpb=48fa2fd17295bcada25a3ee3f2c6f88d273484ac;p=rust-lightning diff --git a/lightning/src/offers/parse.rs b/lightning/src/offers/parse.rs index 6afd4d68..42ed2e00 100644 --- a/lightning/src/offers/parse.rs +++ b/lightning/src/offers/parse.rs @@ -116,6 +116,8 @@ impl TryFrom> for ParsedMessage { } /// Error when parsing a bech32 encoded message using [`str::parse`]. +/// +/// This is not exported to bindings users as its name conflicts with the BOLT 11 ParseError type. #[derive(Debug, PartialEq)] pub enum ParseError { /// The bech32 encoding does not conform to the BOLT 12 requirements for continuing messages @@ -135,6 +137,8 @@ pub enum ParseError { } /// Error when interpreting a TLV stream as a specific type. +/// +/// This is not exported to bindings users as its name conflicts with the BOLT 11 SemanticError type. #[derive(Debug, PartialEq)] pub enum SemanticError { /// The current [`std::time::SystemTime`] is past the offer or invoice's expiration. @@ -171,6 +175,8 @@ pub enum SemanticError { InvalidQuantity, /// A quantity or quantity bounds was provided but was not expected. UnexpectedQuantity, + /// Metadata could not be used to verify the offers message. + InvalidMetadata, /// Metadata was provided but was not expected. UnexpectedMetadata, /// Payer metadata was expected but was missing.