[trunk push] Update to use new allow warnings API

Re https://github.com/CocoaPods/CocoaPods/pull/2831