chiark / gitweb /
Tidy up: make Option and Vec pass through TextFragment.
authorSimon Tatham <anakin@pobox.com>
Thu, 4 Jan 2024 07:26:14 +0000 (07:26 +0000)
committerSimon Tatham <anakin@pobox.com>
Thu, 4 Jan 2024 08:14:00 +0000 (08:14 +0000)
commit36dd8f4b38f4bb9b525e722798b8a7d4123e71f2
tree5cc989ca62fed6db9f9ebc467183d6898d00e513
parentbddc7f4d0ec62ec00ad51551d1418a6d454d62d4
Tidy up: make Option and Vec pass through TextFragment.

Now if you have an Option<TextFragment>, or a Vec<TextFragment> (or
even, heaven help you, an Option<Vec> or a Vec<Option<Vec>> etc), you
can just call .render() on the whole thing without having to manually
loop over it. I'm starting to like this feature of Rust!
src/text.rs