mirror of
https://github.com/erg-lang/erg.git
synced 2025-09-29 20:34:44 +00:00
impl Display for ComileErrors
This commit is contained in:
parent
666ec1c7fe
commit
d8e2ece224
3 changed files with 15 additions and 7 deletions
|
@ -1,6 +1,8 @@
|
|||
//! defines `ParseError` and others.
|
||||
//!
|
||||
//! パーサーが出すエラーを定義
|
||||
use std::fmt;
|
||||
|
||||
use erg_common::astr::AtomicStr;
|
||||
use erg_common::config::Input;
|
||||
use erg_common::error::{ErrorCore, ErrorDisplay, ErrorKind::*, Location, MultiErrorDisplay};
|
||||
|
@ -200,6 +202,12 @@ impl_stream_for_wrapper!(ParserRunnerErrors, ParserRunnerError);
|
|||
|
||||
impl MultiErrorDisplay<ParserRunnerError> for ParserRunnerErrors {}
|
||||
|
||||
impl fmt::Display for ParserRunnerErrors {
|
||||
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
|
||||
self.fmt_all(f)
|
||||
}
|
||||
}
|
||||
|
||||
impl ParserRunnerErrors {
|
||||
pub fn convert(input: &Input, errs: ParseErrors, theme: Theme) -> Self {
|
||||
Self(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue