I looked at that briefly during the last fest, but was unsure whether it was too entangled with the GiST patches that Heikki was looking at.
Recalling my memories of this morning, things are rather independent.
Right. I also looked at it briefly, but I wasn't sure if we really want it. AFAICT, no-one has actually asked for that operator, it was written only to be an example of an operator that would benefit from the knn-gist with recheck patch. If there is some other, real, use for the knn-gist with recheck patch, then I'm OK with that, but otherwise it's dubious to add an operator just so that it can then be made faster by another patch. That said, it seems quite harmless, so might as well commit it.
Lack of recheck is major limitation of KNN-GiST now. People are not asking for that because they don't know what is needed to implement exact KNN for PostGIS. Now they have to invent kluges like this:
WITH closest_candidates AS ( SELECT streets.gid, streets.name, streets.geom FROM nyc_streets streets ORDER BY streets.geom <-> 'SRID=26918;POINT(583571.905921312 4506714.34119218)'::geometry LIMIT 100 ) SELECT gid, name FROM closest_candidates ORDER BY ST_Distance( geom, 'SRID=26918;POINT(583571.905921312 4506714.34119218)'::geometry ) LIMIT 1;