allow nested reads
refactored trec_is_parent
cleanup