aboutsummaryrefslogtreecommitdiffstats
path: root/src/construct/list_item.rs
diff options
context:
space:
mode:
authorLibravatar Titus Wormer <tituswormer@gmail.com>2022-10-14 10:11:59 +0200
committerLibravatar Titus Wormer <tituswormer@gmail.com>2022-10-14 10:11:59 +0200
commitefd20b4999d51fed3ff641f922da05e8bb2481a0 (patch)
treeb6ed7ba04d1f020e119364821badff056b17a058 /src/construct/list_item.rs
parent95f66dc8b4a8cb4c40aa6e4b231bafde516a68bc (diff)
downloadmarkdown-rs-efd20b4999d51fed3ff641f922da05e8bb2481a0.tar.gz
markdown-rs-efd20b4999d51fed3ff641f922da05e8bb2481a0.tar.bz2
markdown-rs-efd20b4999d51fed3ff641f922da05e8bb2481a0.zip
Remove some unused code around slices
Diffstat (limited to '')
-rw-r--r--src/construct/list_item.rs7
1 files changed, 1 insertions, 6 deletions
diff --git a/src/construct/list_item.rs b/src/construct/list_item.rs
index 87cf0b1..ff22d3b 100644
--- a/src/construct/list_item.rs
+++ b/src/construct/list_item.rs
@@ -386,12 +386,7 @@ pub fn resolve(tokenizer: &mut Tokenizer) -> Option<Subresult> {
let end = skip::opt(&tokenizer.events, index, &[Name::ListItem]) - 1;
let marker = skip::to(&tokenizer.events, index, &[Name::ListItemMarker]);
// Guaranteed to be a valid ASCII byte.
- let marker = Slice::from_index(
- tokenizer.parse_state.bytes,
- tokenizer.events[marker].point.index,
- )
- .head()
- .unwrap();
+ let marker = tokenizer.parse_state.bytes[tokenizer.events[marker].point.index];
let current = (marker, balance, index, end);
let mut list_index = lists_wip.len();