Generate class for each enum type

This allows us to patch methods to enum types.
Handle multiple syntax trees sharing a common annotation table

This also changes how syntax tree is hashed to handle the case that
identical C source files have different paths (and thus syntax trees are
hashed differently).