refactor: cleanup utils macros

This commit is contained in:
PoiScript 2019-02-07 15:54:16 +08:00
parent 346ebc83d7
commit 0b355b498c
18 changed files with 285 additions and 297 deletions

View file

@ -414,6 +414,8 @@ impl<'a> Iterator for Parser<'a> {
.cloned()
.map(|x| match x {
Container::Headline { beg, end } => {
debug_assert!(self.off >= beg);
debug_assert!(self.off <= end);
if self.off >= end {
self.end()
} else if self.off == beg {