[][src]Trait artichoke_backend::prelude::Warn

pub trait Warn {
    type Error;
    pub fn warn(&mut self, message: &[u8]) -> Result<(), Self::Error>;
}

Emit warnings during interpreter execution to stderr.

Some functionality required to be compliant with ruby/spec is deprecated or invalid behavior and ruby/spec expects a warning to be emitted to $stderr using the Warning module from the standard library.

Associated Types

type Error[src]

Concrete error type for errors encountered when outputting warnings.

Loading content...

Required methods

pub fn warn(&mut self, message: &[u8]) -> Result<(), Self::Error>[src]

Emit a warning message using Warning#warn.

This method appends newlines to message if necessary.

Errors

Interpreters should issue warnings by calling the warn method on the Warning module.

If an exception is raised on the interpreter, then an error is returned.

Loading content...

Implementors

impl Warn for Artichoke[src]

type Error = Error

Loading content...