changed interface of spawn into non-const attribute