mirror of
https://codeberg.org/demostf/parser.git
synced 2026-06-03 18:24:05 +02:00
minor cleanup
This commit is contained in:
parent
e735ab374f
commit
a9c76eb27c
3 changed files with 718 additions and 1070 deletions
File diff suppressed because it is too large
Load diff
|
|
@ -187,7 +187,7 @@ fn parse_string_table_list(
|
|||
for _ in 0..entry_count {
|
||||
if !stream.read::<bool>()? {
|
||||
return Err(ParseError::InvalidDemo(
|
||||
"there should be no holes when reading CreateStringTable message".to_string(),
|
||||
"there should be no holes when reading CreateStringTable message",
|
||||
));
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -33,7 +33,7 @@ pub enum ParseError {
|
|||
/// String table that was send for update doesn't exist
|
||||
StringTableNotFound(u8),
|
||||
/// A unknown game event type was read
|
||||
UnknownGameEvent(String),
|
||||
UnknownGameEvent(&'static str),
|
||||
/// A read game event doesn't contain the expected values
|
||||
InvalidGameEvent {
|
||||
expected_type: GameEventValueType,
|
||||
|
|
@ -52,7 +52,7 @@ pub enum ParseError {
|
|||
size: u32,
|
||||
},
|
||||
/// Misc malformed demo error
|
||||
InvalidDemo(String),
|
||||
InvalidDemo(&'static str),
|
||||
}
|
||||
|
||||
impl From<ReadError> for ParseError {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue