addMarks marks (mark, points) = tell warning >> return result where
    (ignored, inserted) = partition (`Map.member` marks) points
    warning = map (DuplicateMarkupOmitted . (,) mark) ignored
    result  = marks `Map.union` Map.fromList [(i, mark) | i <- inserted]
addMarks marks (mark, points) = tell warning >> return result where
    (ignored, inserted) = partition (`Map.member` marks) points
    warning = map (DuplicateMarkupOmitted . (,) mark) ignored
    result  = marks `Map.union` Map.fromList [(i, mark) | i <- inserted]
addMarks marks (mark, points) = tell warning >> return result where
    (ignored, inserted) = partition (`Map.member` marks) points
    warning = map (DuplicateMarkupOmitted . (,) mark) ignored
    result  = marks `Map.union` Map.fromList [(i, mark) | i <- inserted]