avm1: Removed errors that are no longer possible to run into

This commit is contained in:
Nathan Adams 2020-06-30 21:28:32 +02:00
parent a989aa235a
commit 47a806a5ee
1 changed files with 0 additions and 12 deletions

View File

@ -9,15 +9,6 @@ pub enum Error<'gc> {
#[error("Couldn't parse SWF. This may or may not be a bug in Ruffle, please help us by reporting it to https://github.com/ruffle-rs/ruffle/issues and include the swf that triggered it.")] #[error("Couldn't parse SWF. This may or may not be a bug in Ruffle, please help us by reporting it to https://github.com/ruffle-rs/ruffle/issues and include the swf that triggered it.")]
InvalidSwf(#[from] swf::error::Error), InvalidSwf(#[from] swf::error::Error),
#[error("No stack frame to execute. This is probably a bug in Ruffle, please report it to https://github.com/ruffle-rs/ruffle/issues and include the swf that triggered it.")]
NoStackFrame,
#[error("Attempted to run a frame not on the current interpreter stack. This is probably a bug in Ruffle, please report it to https://github.com/ruffle-rs/ruffle/issues and include the swf that triggered it.")]
FrameNotOnStack,
#[error("Attempted to execute the same frame twice. This is probably a bug in Ruffle, please report it to https://github.com/ruffle-rs/ruffle/issues and include the swf that triggered it.")]
AlreadyExecutingFrame,
#[error("A script has thrown a custom error.")] #[error("A script has thrown a custom error.")]
ThrownValue(Value<'gc>), ThrownValue(Value<'gc>),
} }
@ -27,9 +18,6 @@ impl Error<'_> {
match self { match self {
Error::PrototypeRecursionLimit => true, Error::PrototypeRecursionLimit => true,
Error::InvalidSwf(_) => true, Error::InvalidSwf(_) => true,
Error::NoStackFrame => true,
Error::FrameNotOnStack => true,
Error::AlreadyExecutingFrame => false,
Error::ThrownValue(_) => false, Error::ThrownValue(_) => false,
} }
} }