Fix leaked memory context in json_array_each and json_each

json_array_each and json_each leaked a memory context with each
invocation, causing profiles involving many invocations in a single
query context to be dominated by MemoryContextReset because of
MemoryContextResetChildren calls made after each tuple is emitted.

See initial bug report:

http://stackoverflow.com/q/21507127/398670

and list discussion:

 http://www.postgresql.org/message-id/52EEEC37.9040305@2ndquadrant.com
New gendef
Make vcregress.pl bail out informatively when there's nothing to test