Switch ScriptModuleOp to use a unique_ptr
Summary: Pull Request resolved: https://github.com/pytorch/pytorch/pull/29856
Test Plan: waitforsadcastle
Reviewed By: dzhulgakov
Differential Revision: D18516553
fbshipit-source-id: d1e2d49ec613d07b21cd30bd777fbd300032cba1