mirror of
https://github.com/nushell/reedline.git
synced 2024-09-11 15:55:50 +03:00
Allow to construct ReedlineError values from the outside (#676)
This commit is contained in:
parent
37714c922e
commit
07b7f6bb76
@ -3,7 +3,7 @@ use thiserror::Error;
|
||||
|
||||
/// non-public (for now)
|
||||
#[derive(Error, Debug)]
|
||||
pub(crate) enum ReedlineErrorVariants {
|
||||
pub enum ReedlineErrorVariants {
|
||||
// todo: we should probably be more specific here
|
||||
#[cfg(any(feature = "sqlite", feature = "sqlite-dynlib"))]
|
||||
#[error("error within history database: {0}")]
|
||||
@ -21,7 +21,7 @@ pub(crate) enum ReedlineErrorVariants {
|
||||
|
||||
/// separate struct to not expose anything to the public (for now)
|
||||
#[derive(Debug)]
|
||||
pub struct ReedlineError(pub(crate) ReedlineErrorVariants);
|
||||
pub struct ReedlineError(pub ReedlineErrorVariants);
|
||||
|
||||
impl Display for ReedlineError {
|
||||
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
||||
|
Loading…
Reference in New Issue
Block a user