cs-completer: improved automatic solution detection