diff options
author | Justus Winter <justus@sequoia-pgp.org> | 2022-05-11 14:12:42 +0200 |
---|---|---|
committer | Justus Winter <justus@sequoia-pgp.org> | 2022-05-11 15:36:07 +0200 |
commit | dfa22b657ba582cb03c0895d56b1513d4b9b8cd2 (patch) | |
tree | d2d9219955175264ad5d7d97b4feb2d09045e3ea /openpgp/src/cert | |
parent | d622f0e35b155c686329ed99aa6042469f3f3cbb (diff) |
openpgp: Fix comments.
Diffstat (limited to 'openpgp/src/cert')
-rw-r--r-- | openpgp/src/cert/parser/low_level/grammar.lalrpop | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/openpgp/src/cert/parser/low_level/grammar.lalrpop b/openpgp/src/cert/parser/low_level/grammar.lalrpop index c4759899..d81ff6e3 100644 --- a/openpgp/src/cert/parser/low_level/grammar.lalrpop +++ b/openpgp/src/cert/parser/low_level/grammar.lalrpop @@ -86,7 +86,7 @@ pub Cert: Option<Cert> = { }) } None => { - // Just validating a message... + // Just validating a cert... assert!(c.is_none() || c.unwrap().len() == 0); Ok(None) } @@ -101,7 +101,7 @@ Primary: Option<(Packet, Vec<Signature>)> = { if let Some(pk) = pk { Some((pk, sigs.unwrap())) } else { - // Just validating a message... + // Just validating a cert... assert!(sigs.is_none() || sigs.unwrap().len() == 0); None } @@ -129,7 +129,7 @@ OptionalSignatures: Option<Vec<Signature>> = { assert!(sigs.is_some()); sigs } - // Just validating a message... + // Just validating a cert... Token::Signature(None) => return None, tok => unreachable!("Expected signature token, got {:?}", tok), } @@ -148,7 +148,7 @@ OptionalComponents: Option<Vec<Component>> = { cs.push(c); Some(cs) } else { - // Just validating a message... + // Just validating a cert... None } }, @@ -171,7 +171,7 @@ Component: Option<Component> = { other_revocations: vec![], })) }, - // Just validating a message... + // Just validating a cert... None => None, } }, @@ -191,7 +191,7 @@ Component: Option<Component> = { other_revocations: vec![], })) }, - // Just validating a message... + // Just validating a cert... None => None, } }, @@ -211,7 +211,7 @@ Component: Option<Component> = { other_revocations: vec![], })) }, - // Just validating a message... + // Just validating a cert... None => None, } }, @@ -231,7 +231,7 @@ Component: Option<Component> = { other_revocations: vec![], })) }, - // Just validating a message... + // Just validating a cert... None => None, } }, @@ -241,7 +241,7 @@ Subkey: Option<Key<key::PublicParts, key::SubordinateRole>> = { <t:PUBLIC_SUBKEY> => { match t.into() { Some(Packet::PublicSubkey(key)) => Some(key), - // Just validating a message... + // Just validating a cert... None => None, Some(pkt) => unreachable!("Expected public subkey packet, got {:?}", pkt), @@ -250,7 +250,7 @@ Subkey: Option<Key<key::PublicParts, key::SubordinateRole>> = { <t:SECRET_SUBKEY> => { match t.into() { Some(Packet::SecretSubkey(key)) => Some(key.parts_into_public()), - // Just validating a message... + // Just validating a cert... None => None, Some(pkt) => unreachable!("Expected secret subkey packet, got {:?}", pkt), @@ -262,7 +262,7 @@ UserID: Option<UserID> = { <t:USERID> => { match t.into() { Some(Packet::UserID(u)) => Some(u), - // Just validating a message... + // Just validating a cert... None => None, Some(pkt) => unreachable!("Expected user id packet, got {:?}", pkt), @@ -274,7 +274,7 @@ UserAttribute: Option<UserAttribute> = { <t:USER_ATTRIBUTE> => { match t.into() { Some(Packet::UserAttribute(u)) => Some(u), - // Just validating a message... + // Just validating a cert... None => None, Some(pkt) => unreachable!("Expected user attribute packet, got {:?}", pkt), @@ -286,7 +286,7 @@ Unknown: Option<Unknown> = { <t:UNKNOWN> => { match t.into() { Some(Packet::Unknown(u)) => Some(u), - // Just validating a message... + // Just validating a cert... None => None, Some(pkt) => unreachable!("Expected unknown packet, got {:?}", pkt), |