Fixed the generation of fields of a type def type by correctly desugaring.

Signed-off-by: Dimitar Dobrev <dpldobrev@yahoo.com>
Merge pull request #74 from ddobrev/master

Fixed the generation of fields of a type def type by correctly desugaring