pub trait LocatedEncoder: Send + Sync {
// Required method
fn encode_located(
&self,
cx: &mut WriteCx<'_>,
expr: &LocatedExpr,
) -> Result<Output>;
}Expand description
An encoder that consumes a LocatedExpr, able to use source origin for a
higher-fidelity rendering than the plain Encoder.
Required Methods§
Sourcefn encode_located(
&self,
cx: &mut WriteCx<'_>,
expr: &LocatedExpr,
) -> Result<Output>
fn encode_located( &self, cx: &mut WriteCx<'_>, expr: &LocatedExpr, ) -> Result<Output>
Encode a LocatedExpr, optionally using its origin for fidelity.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".