mirror of
https://github.com/RGBCube/serenity
synced 2025-05-14 09:04:59 +00:00
AK: Use ErrorOr<T> for MappedFile factories
Replace Result<T, E> with ErrorOr<T> and propagate the error to callers.
This commit is contained in:
parent
c837bd551e
commit
0f5477c721
12 changed files with 54 additions and 64 deletions
|
@ -28,7 +28,7 @@ int main(int argc, char** argv)
|
|||
|
||||
auto file_or_error = MappedFile::map(path);
|
||||
if (file_or_error.is_error()) {
|
||||
warnln("Could not map file: {}", file_or_error.error().string());
|
||||
warnln("Could not map file: {}", file_or_error.error());
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue