natter/src/intermediate/plain_text.rs

16 lines
380 B
Rust
Raw Normal View History

use super::macros::intermediate;
use super::registry::Registry;
use super::util::coalesce_whitespace;
use crate::error::CustomError;
2023-10-29 19:36:15 +00:00
#[derive(Debug, Clone)]
pub(crate) struct IPlainText {
2023-10-27 23:42:33 +00:00
pub(crate) source: String,
}
intermediate!(IPlainText, PlainText, original, registry, {
Ok(IPlainText {
source: coalesce_whitespace(original.source).into_owned(),
})
});