Check if codemirror returns a TextMark object