memory manager must not be created when returning references [ci skip]