static_web_server/
error.rs

1// SPDX-License-Identifier: MIT OR Apache-2.0
2// This file is part of Static Web Server.
3// See https://static-web-server.net/ for more information
4// Copyright (C) 2019-present Jose Quintana <joseluisq.net>
5
6//! Useful error type re-exports based on [anyhow][mod@anyhow].
7//!
8
9/// Just a `anyhow::Result` type alias.
10pub type Result<T = (), E = anyhow::Error> = anyhow::Result<T, E>;
11
12/// Just an `anyhow::Error` type alias.
13pub type Error = anyhow::Error;
14
15/// Just re-export some `anyhow` stuff.
16pub use anyhow::anyhow;
17pub use anyhow::bail;
18pub use anyhow::Context;