Constify XirrState in finalization functions