Remove grotty special-case code in coerce_to_target_type() that
Tom Lane <tgl@sss.pgh.pa.us>
Remove grotty special-case code in coerce_to_target_type() that implemented casts to varchar and bpchar using a cast-to-text function. This is a holdover from before we had pg_cast; it now makes more sense to just list these casts in pg_cast. While at it, add pg_cast entries for the other direction (casts from varchar/bpchar) where feasible.
Files
| Path | Change | +/− |
|---|---|---|
| src/backend/parser/parse_coerce.c | modified | +1 −45 |
| src/include/catalog/catversion.h | modified | +2 −2 |
| src/include/catalog/pg_cast.h | modified | +84 −4 |
| src/test/regress/expected/opr_sanity.out | modified | +7 −1 |
| src/test/regress/sql/opr_sanity.sql | modified | +7 −1 |