In C and C++, enumerators can have a trailing comma. The same can be said when initializing an array, but I’ll consider that a less important topic, for another time. Having these trailing commas is beneficial because when these are listed on separate lines, adding a new element can be performed without changing any existing lines.
enum Color
{
Red,
Blue // <- non-compliant, missing comma
};
enum Color
{
Red,
Blue, // <- compliant, comma
};
I suppose the same would be relevant for other languages as well.