Finalize structure