may not work as const_iterator, have to check it first