support for non RA with length in startWith

As suggested by Andrei.

Also: More unittests