mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 22:48:11 +00:00
AK: Remove the fallible constructor from FixedMemoryStream
This commit is contained in:
parent
8b2f23d016
commit
220fbcaa7e
31 changed files with 185 additions and 209 deletions
|
@ -260,8 +260,8 @@ ParseResult<BlockType> BlockType::parse(AK::Stream& stream)
|
|||
return BlockType {};
|
||||
|
||||
{
|
||||
auto value_stream = FixedMemoryStream::construct(ReadonlyBytes { &kind, 1 }).release_value_but_fixme_should_propagate_errors();
|
||||
if (auto value_type = ValueType::parse(*value_stream); !value_type.is_error())
|
||||
FixedMemoryStream value_stream { ReadonlyBytes { &kind, 1 } };
|
||||
if (auto value_type = ValueType::parse(value_stream); !value_type.is_error())
|
||||
return BlockType { value_type.release_value() };
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue