diff options
author | Tom Lane | 2015-05-21 23:47:48 +0000 |
---|---|---|
committer | Tom Lane | 2015-05-21 23:47:48 +0000 |
commit | c5dd8ead403f85bd041590d2e3e79b72830472d4 (patch) | |
tree | 33bf4aa4143e930af0f5aadc3c894c0bb568d09c /src/include/access/genam.h | |
parent | d4b538ea367de43b2f2b939621272682417cd290 (diff) |
More fixes for lossy-GiST-distance-functions patch.
Paul Ramsey reported that commit 35fcb1b3d038a501f3f4c87c05630095abaaadab
induced a core dump on commuted ORDER BY expressions, because it was
assuming that the indexorderby expression could be found verbatim in the
relevant equivalence class, but it wasn't there. We really don't need
anything that complicated anyway; for the data types likely to be used for
index ORDER BY operators in the foreseeable future, the exprType() of the
ORDER BY expression will serve fine. (The case where we'd have to work
harder is where the ORDER BY expression's result is only binary-compatible
with the declared input type of the ordering operator; long before worrying
about that, one would need to get rid of GiST's hard-wired assumption that
said datatype is float8.)
Aside from fixing that crash and adding a regression test for the case,
I did some desultory code review:
nodeIndexscan.c was likewise overthinking how hard it ought to work to
identify the datatype of the ORDER BY expressions.
Add comments explaining how come nodeIndexscan.c can get away with
simplifying assumptions about NULLS LAST ordering and no backward scan.
Revert no-longer-needed changes of find_ec_member_for_tle(); while the
new definition was no worse than the old, it wasn't better either, and
it might cause back-patching pain.
Revert entirely bogus additions to genam.h.
Diffstat (limited to 'src/include/access/genam.h')
-rw-r--r-- | src/include/access/genam.h | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/src/include/access/genam.h b/src/include/access/genam.h index f129c4b58f9..d86590ac111 100644 --- a/src/include/access/genam.h +++ b/src/include/access/genam.h @@ -147,10 +147,7 @@ extern void index_restrpos(IndexScanDesc scan); extern ItemPointer index_getnext_tid(IndexScanDesc scan, ScanDirection direction); extern HeapTuple index_fetch_heap(IndexScanDesc scan); -extern bool index_get_heap_values(IndexScanDesc scan, ItemPointer heapPtr, - Datum values[INDEX_MAX_KEYS], bool isnull[INDEX_MAX_KEYS]); extern HeapTuple index_getnext(IndexScanDesc scan, ScanDirection direction); - extern int64 index_getbitmap(IndexScanDesc scan, TIDBitmap *bitmap); extern IndexBulkDeleteResult *index_bulk_delete(IndexVacuumInfo *info, |