@@ -88,11 +88,13 @@ combineReducibles r s =
89 case null shared of
89 case null shared of
90 True | (x : xs) <- reverse rs
90 True | (x : xs) <- reverse rs
91− , isSpace x ->
91+ , isSpace x -> case xs of
92− rebuild conts (reverse xs) ++ [x, s]
93+ _ -> rebuild conts (reverse xs) ++ [x, s]
93 | (x : xs) <- ss
94 | (x : xs) <- ss
94− , isSpace x ->
95+ , isSpace x -> case xs of
95− [r, x] ++ rebuild conts' (xs)
97+ _ -> [r, x] ++ rebuild conts' (xs)
96 True -> [r,s]
98 True -> [r,s]
97 False -> rebuild
99 False -> rebuild
@@ -121,7 +123,6 @@ instance Reducible Inline where
121 False -> [Span attr2' ils2]
123 False -> [Span attr2' ils2]
123 [Span attr' $ reduceList $ s1' ++ s2']
125 [Span attr' $ reduceList $ s1' ++ s2']
125 (Str x) <++> (Str y) = [Str (x++y)]
126 (Str x) <++> (Str y) = [Str (x++y)]
126 il <++> il' = combineReducibles il il'
127 il <++> il' = combineReducibles il il'