1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
use crate::{Result, Tape, Walue};
index! {
@define
#[doc = "A character-string index."]
pub CharacterStrings
}
impl Walue<'static> for CharacterStrings {
type Parameter = i32;
fn read<T: Tape>(tape: &mut T, format: i32) -> Result<Self> {
Ok(match format {
2 => CharacterStrings(tape.take()?),
format => raise!(
"found an unsupported format of character strings ({})",
format,
),
})
}
}