Adding accessor to diagnostic msg shared ptr.