Ticket #484 (closed task: fixed)
[raster] rtpostgis.sql.in.c using old style 1.3 syntax and other arcane stuff
|Reported by:||robe||Owned by:||pracine|
This I'm not sure you want to change just yet and I forget why we had this convention in 1.3. I think it was to support older PostgreSQL installs like 8.1.
I see in your function you have
CREATEFUNCTION st_convexhull(raster) RETURNS GEOMETRY AS 'MODULE_PATHNAME','RASTER_convex_hull' LANGUAGE 'C' _IMMUTABLE_STRICT;
We do now (though I guess you may want to leave costs out if you want 8.2 users to be able to use it)
CREATE OR REPLACE FUNCTION ST_ConvexHull(geometry) RETURNS geometry AS 'MODULE_PATHNAME','convexhull' LANGUAGE 'C' IMMUTABLE STRICT COST 100;
On a side note, I see you have inherited our bad habits of not naming the variables going into input. This was done a long time ago I think pre 8.0 before it was okay to put names of variables in the input. Probably not too worthwhile changing now except its confusing reading it when you see integer that that goes to band number or float8 is x etc. Again postgis sql.in.c files are more guilty of this atrocity.
Also you are not always using $ quoting syntax which is much easier to read and has been supported since PostgreSQL 8.0. Admittedly the whole PostGIS code sql file is guilty of this atrocity and worse so so can't complain too much.
Just thought I'd butt my nose in :)