pub trait EmitExt: Emit {
// Required methods
fn write_to_stdout(&self, session: &Session) -> Result<()>;
fn write_to_file(
&self,
path: &Path,
mode: OutputMode,
session: &Session,
) -> Result<()>;
}Required Methods§
Sourcefn write_to_stdout(&self, session: &Session) -> Result<()>
fn write_to_stdout(&self, session: &Session) -> Result<()>
Write this item to standard output, inferring the best OutputMode based on whether or not stdout is a tty or not
Sourcefn write_to_file(
&self,
path: &Path,
mode: OutputMode,
session: &Session,
) -> Result<()>
fn write_to_file( &self, path: &Path, mode: OutputMode, session: &Session, ) -> Result<()>
Write this item to the given file path, using mode to determine the output type
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.