Introduce the Atom class

We now use a proper class instead of just integers for type atoms. The ability
to have methods thereupon greatly simplifies the code.

Signed-off-by: Casey Dahlin <casey.dahlin@gmail.com>