From 2e1eec5fe4157a391a13554ff7df3075cfe043cc Mon Sep 17 00:00:00 2001 From: Justus Winter Date: Thu, 9 Apr 2020 16:42:59 +0200 Subject: openpgp: Make PacketParserResult a std::result::Result. - This avoids the partial implementation imitating std::option::Option, replacing it with std::result::Result. - As a benefit, std::result::Result is in the prelude, simplifying a lot of parsing loops. --- openpgp/src/crypto/s2k.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'openpgp/src/crypto/s2k.rs') diff --git a/openpgp/src/crypto/s2k.rs b/openpgp/src/crypto/s2k.rs index 8dff4693..40a26bda 100644 --- a/openpgp/src/crypto/s2k.rs +++ b/openpgp/src/crypto/s2k.rs @@ -416,7 +416,7 @@ mod tests { // Get the next packet. let (_, ppr) = pp.next().unwrap(); - assert!(ppr.is_none()); + assert!(ppr.is_err()); } } -- cgit v1.2.3