Improved support for object property shorthand. Fixes gh-1813

cc @caitp 
This is the only important part of the patch. Sorry for the noise.