Skip to content
Myr

Specify types where the manual vtable relies on them

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by David Tolnay · committed by David Tolnay · parent a2846fd · Browse files · 1 file+3 added−3 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+3 added−3 removed

  • other:+3 added−3 removed

1 file+3 added−3 removed

modified:src/error.rs+3 added-3 removed
42 unmodified lines
43 pub(crate) fn from_adhoc<M>(message: M, backtrace: Option<Backtrace>) -> Self44 where45 M: Display + Debug + Send + Sync + 'static,46 {47 let error = MessageError(message);47 let error: MessageError<M> = MessageError(message);48 let vtable = &ErrorVTable {49 object_drop: object_drop::<MessageError<M>>,50 object_drop_front: object_drop_front::<MessageError<M>>,51 object_ref: object_ref::<MessageError<M>>,
10 unmodified lines
62 pub(crate) fn from_display<M>(message: M, backtrace: Option<Backtrace>) -> Self63 where64 M: Display + Send + Sync + 'static,65 {66 let error = DisplayError(message);66 let error: DisplayError<M> = DisplayError(message);67 let vtable = &ErrorVTable {68 object_drop: object_drop::<DisplayError<M>>,69 object_drop_front: object_drop_front::<DisplayError<M>>,70 object_ref: object_ref::<DisplayError<M>>,
95 unmodified lines
166 pub fn context<C>(self, context: C) -> Self167 where168 C: Display + Send + Sync + 'static,169 {170 let error = ContextError {170 let error: ContextError<C, Error> = ContextError {171 context,172 error: self,173 };174
454 unmodified lines