) => (
parse_node!(
[$(: $tags ($(:$tag_nodes),*))*];
- [$(:$head_nodes,)* :tag(stringify!($head).to_owned(),
+ [$(:$head_nodes,)* :tag(stringify!($head).to_strbuf(),
vec!($($nodes),*))];
$($rest)*
)
) => (
parse_node!(
[$(: $tags ($(:$tag_nodes),*))*];
- [$(:$nodes,)* :text(".".to_owned())];
+ [$(:$nodes,)* :text(".".to_strbuf())];
$($rest)*
)
);
) => (
parse_node!(
[$(: $tags ($(:$tag_nodes),*))*];
- [$(:$nodes,)* :text(stringify!($word).to_owned())];
+ [$(:$nodes,)* :text(stringify!($word).to_strbuf())];
$($rest)*
)
);
}
enum HTMLFragment {
- tag(~str, Vec<HTMLFragment> ),
- text(~str),
+ tag(StrBuf, Vec<HTMLFragment> ),
+ text(StrBuf),
}