[−][src]Enum pir_8_emu::binutils::pir_8_as::AssemblerDirectiveObeyError
pub enum AssemblerDirectiveObeyError<'s> { LabelNameTaken(&'s str), OutputAddressAlreadySet(u16, u16), }
An error that could've occurred when obeying an asembly directive.
Examples
let mut next_output_address = Some(0x0110); let mut labels = vec![("uwu".to_string(), 0x0069)].into_iter().collect(); assert_eq!(AssemblerDirective::SetOrigin(0x0420).obey(&mut next_output_address, &mut labels), Err(AssemblerDirectiveObeyError::OutputAddressAlreadySet(0x0110, 0x0420))); assert_eq!(AssemblerDirective::SaveLabel("uwu").obey(&mut next_output_address, &mut labels), Err(AssemblerDirectiveObeyError::LabelNameTaken("uwu")));
Variants
LabelNameTaken(&'s str)
The label wit hthe specified name already exists
An origin was attempted to be specified with the output address already existing
First argument is the current output address, the second – the requested
Trait Implementations
impl<'s> Clone for AssemblerDirectiveObeyError<'s>
[src][+]
impl<'s> Copy for AssemblerDirectiveObeyError<'s>
[src]
impl<'s> Debug for AssemblerDirectiveObeyError<'s>
[src][+]
impl<'_> Display for AssemblerDirectiveObeyError<'_>
[src][+]
impl<'s> Eq for AssemblerDirectiveObeyError<'s>
[src]
impl<'_> Error for AssemblerDirectiveObeyError<'_>
[src][+]
impl<'s> Hash for AssemblerDirectiveObeyError<'s>
[src][+]
impl<'s> Ord for AssemblerDirectiveObeyError<'s>
[src][+]
impl<'s> PartialEq<AssemblerDirectiveObeyError<'s>> for AssemblerDirectiveObeyError<'s>
[src][+]
impl<'s> PartialOrd<AssemblerDirectiveObeyError<'s>> for AssemblerDirectiveObeyError<'s>
[src][+]
impl<'s> StructuralEq for AssemblerDirectiveObeyError<'s>
[src]
impl<'s> StructuralPartialEq for AssemblerDirectiveObeyError<'s>
[src]
Auto Trait Implementations
impl<'s> RefUnwindSafe for AssemblerDirectiveObeyError<'s>
impl<'s> Send for AssemblerDirectiveObeyError<'s>
impl<'s> Sync for AssemblerDirectiveObeyError<'s>
impl<'s> Unpin for AssemblerDirectiveObeyError<'s>
impl<'s> UnwindSafe for AssemblerDirectiveObeyError<'s>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src][+]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src][+]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src][+]
T: ?Sized,
impl<T> Downcast for T where
T: Any,
[src][+]
T: Any,
impl<T> DowncastSync for T where
T: Send + Sync + Any,
[src][+]
T: Send + Sync + Any,
impl<T> From<T> for T
[src][+]
impl<T, U> Into<U> for T where
U: From<T>,
[src][+]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src][+]
T: Clone,
impl<T> ToString for T where
T: Display + ?Sized,
[src][+]
T: Display + ?Sized,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src][+]
U: Into<T>,
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src][+]
U: TryFrom<T>,