How useful is the feature of having an atom data type in a programming language?
A few programming languages have the concept of atom or symbol to represent a consta
The problem I have with similar concepts in other languages (eg, C) can be easily expressed as:
#define RED 1
#define BLUE 2
#define BIG 1
#define SMALL 2
or
enum colors { RED, BLUE };
enum sizes { BIG, SMALL };
Which causes problems such as:
if (RED == BIG)
printf("True");
if (BLUE == 2)
printf("True");
Neither of which really make sense. Atoms solve a similar problem without the drawbacks noted above.