Fix exception in case of contiguous delimiters. Add test case.