natter/src/intermediate/timestamp.rs
Tom Alexander 7d73a3c948
Clean up.
2025-02-22 19:24:05 -05:00

24 lines
576 B
Rust

use super::macros::intermediate;
use super::util::coalesce_whitespace;
use crate::error::CustomError;
use organic::types::StandardProperties;
#[derive(Debug, Clone)]
pub(crate) struct ITimestamp {
pub(crate) source: String,
pub(crate) post_blank: organic::types::PostBlank,
}
intermediate!(
ITimestamp,
&'orig organic::types::Timestamp<'parse>,
original,
_intermediate_context,
{
Ok(ITimestamp {
source: coalesce_whitespace(original.source).into_owned(),
post_blank: original.get_post_blank(),
})
}
);