He formerly served as Lord Justice General and Lord President of the Court of Session, and was an additional Lord of Appeal in the House of Lords prior to the transfer of its judicial functions to the Supreme Court.