Add queryWith, a qeury taking RowParser as argument

Helps with writing higher level libraries using postgresql-simple
Merge pull request #89 from sopvop/queryWith

Add queryWith, a query taking RowParser as argument
Regression test for #90

The smoke test is hardly adequate, but it exposes the current issue.
Add Default type with a ToField instance
Bump Version
CHANGES
Copy every field,  all the time.

This change is for improved performance in typical use cases.
Unfortunately, this is a tradeoff,  and not always a win either

It turns out that `LibPQ.getvalue'` is substantially faster for small
bytestrings than `LibPQ.getvalue`.   Apparently,  this is due to the
fact that `getvalue'` (indirectly) calls `mallocForeignPtrBytes`,  which
is "heavily optimized",  whereas `getvalue` calls `newForeignPtr` and
sets up a finalizer that touches the  `LibPQ.Result` to prevent it from
being freed by GHC's garbage collector.

Presumably,  there is a point at which `getvalue` becomes faster than
`getvalue'`,  as the former should be O(1) whereas the latter is `O(n)` due
to memcpy.   However,  for common use cases this is a moot point,
as postgresql-simple does a memcpy upon conversion to a `ByteString`
anyway.

The other conversions don't copy the memory,  but most types are
guaranteed to be short enough that this switch is a win.   The only
pre-packaged conversions where this change is a loss is when dealing
with big arrays,  big hstores,  and big json documents.   Just how big
where the crossover point is needs to be researched.
Add FromField instances for IORefs and MVars
Add PGArray Type

Credit to Joey Adams;  closes #50
Fix Json decoding

Closes #90.  Thanks to Amit Levy for the report.
See also #79, #80, #81, and #83.   Looks like CPP was needed after all.
Add FromField instance for IOVector
Version 0.4.0.0;  CHANGES
Documentation Fixes
Relax dependency on Aeson back to >= 0.6
Version 0.4.0.1; CHANGES
Tweak CPP directive
Tweak testsuite for compatibility with aeson-0.7
Version 0.4.0.2; CHANGES
Bump lower version of postgresql-libpq dependency

This needed to be done a long time ago.  Eep.
add sql identifier newtype using PQ.escapeIdentifier

Also add a qualified sql identifier data type and the corresponding
ToField instances.

Requires postgresql-libpq >=0.9