DATAMONGO-908 - Support for nested field references in group operations.

We now allow referring to nested field expressions if the root segment of the nested field expression was exposed in earlier stages of the aggregation pipeline.

Original pull request: #167.