Provide an error cursor for "can't subscript" error messages.
Tom Lane <tgl@sss.pgh.pa.us>
Provide an error cursor for "can't subscript" error messages. Commit c7aba7c14 didn't add this, but after more fooling with the feature I feel that it'd be useful. To make this possible, refactor getSubscriptingRoutines() so that the caller is responsible for throwing any error. (In clauses.c, I just chose to make the most conservative assumption rather than throwing an error. We don't expect failures there anyway really, so the code space for an error message would be a poor investment.)
Files
| Path | Change | +/− |
|---|---|---|
| src/backend/executor/execExpr.c | modified | +8 −0 |
| src/backend/optimizer/util/clauses.c | modified | +3 −2 |
| src/backend/parser/parse_node.c | modified | +6 −0 |
| src/backend/utils/cache/lsyscache.c | modified | +2 −5 |
| src/test/regress/expected/arrays.out | modified | +2 −0 |