Improved parsing of lookup paths