Improve documentation, tests, and edge-case behaviour for json_object_get_*_member[_with_default]

Will Thompson requested to merge object_get-with-wrong-types into master

Currently, these functions call g_return_val_if_fail() (ie, a programmer error) in several undocumented cases. This MR documents some of these cases, turns others into non-error cases, and also documents and tests some other edge-cases around conversions between scalar values.

Merge request reports