Ensure libmongoc structs get freed in WriteBatch and WriteConcern
Fix typo in constant name
PHP-1172: Implement WriteError class

Removed getter for bulk operation corresponding to the index, since that would require reconstructing zvals from the libmongoc structs.
PHP-1171: Move WriteConcernError init function to php_phongo.c

The functions in each class file are not exported (since we don't have headers), and this ultimately needs to be called by the WriteResult initialization function. Therefore, it's best placed in php_phongo.c for now, as we did with WriteError's function.
PHP-1142: Init WriteError and WriteConcernError arrays for WriteResult

When initializing a WriteResult, we should initialize the corresponding WriteError and WriteConcernError classes, too. This moves all of the initialization code into php_phongoc, as was done with the error classes.

Additionally, phongo_execute_write() has been changed to not construct a bson_t reply unnecessarily (i.e. return value will not be used).
Return exceptions after throwing in case we need to modify them
PHP-1230: Implement WriteException class
Throw WriteException on failed write ops

If available, the WriteResult should be set on the exception
Fix tab indentation for generated C code
PHP-1142: Memory cleanup and getters for WriteResult error zvals
PHP-1142: Implement WriteResult getter for meta information

This getter is intended to return situational fields (e.g. lastOp, electionId), which are not currently supported by libmongoc (see: CDRIVER-428).
PHP-1142: Support upserted ids in WriteResult

Renamed getGeneratedIdsForUpsert() to getUpsertedIds().
PHP-1142: Dump WriteResult object in write tests
Use correct return types for WriteResult-related init functions

We never check whether WriteResult init succeeds, which is fine as it sets whatever it can on the corresponding object. For the error inits, we actually do care if they succeed or fail so that we can free up the zvals; however, the return types should be booleans.
Merge pull request #16