improvements to enum constant calculations

compute constant values for enum expressions.
emit enum declarations using original syntax.
emit enum definitions using computed constant values.