How to create INOUT assignment cast on Amazon RDS PostgreSQL? If not possible, then why? I'm migrating existing application to Amazon RDS PostgreSQL.
The application has cross-database support and for compatibility reasons it includes the following SQL:

CREATE CAST (varchar AS numeric) WITH INOUT AS ASSIGNMENT


On plain PostgreSQL, this requires superuser. On Amazon RDS PostgreSQL this fails with


  ERROR: must be owner of type character varying or type numeric



Is there a way to create such a cast in Amazon RDS (perhaps via administrative web interface)?
If this is not possible, then why? Is this deliberate limitation (e.g. is the cast something dangerous) or just a missing feature?


Note: I guess that whether this is assignment or implicit cast is irrelevant, but included this information for completeness.
On AWS RDS you must first alter type &lt;type&gt; owner to &lt;user&gt; before create cast since the default owner of all types is the rdsadmin user.

To run alter type you must do so with the master user system account you created for RDS or any other user that you have given the rds_superuser role. From the docs:


  When you create a DB instance, the master user system account that you
  create is assigned to the rds_superuserrole.
  The rds_superuser role is similar to the PostgreSQL superuser role
  (customarily named postgres in local instances) but with some
  restrictions.