Fix warnings in tensor_flatten.cpp (#55956)
Summary:
Switch to use `TensorOptions` instead of deprecated `.type()` to fix compiler warnings as part of #55952
](https://our.intern.facebook.com/intern/diff/27830504/)
Pull Request resolved: https://github.com/pytorch/pytorch/pull/55956
Pulled By: driazati
Reviewed By: pritamdamania87
Differential Revision: D27830504
fbshipit-source-id: f705818ddb7d8b17c0f5383f22dc431203a194d9
Author
davidriazati@fb.com