Clean up name resolution a bit