adapts TPath to plain Perl data structures