aboutsummaryrefslogtreecommitdiffstats
path: root/src/util
diff options
context:
space:
mode:
authorLibravatar Titus Wormer <tituswormer@gmail.com>2022-10-14 12:20:08 +0200
committerLibravatar Titus Wormer <tituswormer@gmail.com>2022-10-14 12:20:08 +0200
commit6a727f4d67bef60f4aed4d3cbccd42226a338843 (patch)
treeaecb2684343d8f61f30c84032305bd2b0152b467 /src/util
parent0e4c4b5e63efd2a2bee038e69faf1aedb14a2043 (diff)
downloadmarkdown-rs-6a727f4d67bef60f4aed4d3cbccd42226a338843.tar.gz
markdown-rs-6a727f4d67bef60f4aed4d3cbccd42226a338843.tar.bz2
markdown-rs-6a727f4d67bef60f4aed4d3cbccd42226a338843.zip
Attempt to fix broken tarpaulin
Diffstat (limited to '')
-rw-r--r--src/util/slice.rs2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/util/slice.rs b/src/util/slice.rs
index 869ecca..ab3064a 100644
--- a/src/util/slice.rs
+++ b/src/util/slice.rs
@@ -24,6 +24,7 @@ impl<'a> Position<'a> {
///
/// This function panics if an enter event is given.
/// When `markdown-rs` is used, this function never panics.
+ #[cfg_attr(tarpaulin, ignore)]
pub fn from_exit_event(events: &'a [Event], index: usize) -> Position<'a> {
let exit = &events[index];
debug_assert_eq!(exit.kind, Kind::Exit, "expected `exit` event");
@@ -117,6 +118,7 @@ impl<'a> Slice<'a> {
/// Turn the slice into a `String`.
///
/// Supports virtual spaces.
+ #[cfg_attr(tarpaulin, ignore)]
pub fn serialize(&self) -> String {
debug_assert_eq!(self.after, 0, "expected no trailing vs");
// If the above ever starts erroring, handle the same as `self.before`