TypeResolver and MappingContext updates

Small fixes for issues #83 and #81