Hm, no, I don't see how you would be able to "check for ::quote". Either you use ::quote in your code, in which case you'll get a compilation error if it doesn't exist, or you don't, in which case you can't check for it...
You could overload `[] and simply not define quote in Sql.postgres at all, but that would be rather disgusting. :-9