Fix ArrayIndexOutOfBoundsException in TreeBuilder when an invalid separator
regex is given that results in a split array with 0 length.