Dalrymple, David, Sir, active 1762-1821, 3rd Baronet, Lord Hailes