Or, design and use languages where such commas are not needed, or campaign to get the commas removed in array and dict notation. In all the cases given, removing comma introduces no ambiguity.
There is also the fact that some coding standards prefer comma in front, eliminating need for dangling commas
Comma in front has always been my go-to but it’s definitely head-spinning trying to come up with easily readable formatting for sizeable expressions (“functional” imperative programming) in c-style languages; not only is there the comma issue in function parameters and array constructors, but there’s 3-4 different kinds of nesting at any given time: function-in-function, infix-ish expressions like ternary operators, dot-syntax methods/promises/etc, not to mention the road hazard that is huge type declarations hanging out mid-expression in casts and generics. Sometimes I feel bad for my colleagues that have to maintain categorically unreadable code.
Or just… don’t design languages where commas are the separator. Use semicolons for everything you’d otherwise use commas for. Then everybody’s aesthetics are satisfied, except that a few more pixels are darkened, which I realize gives the language a measurably less friendly feel, but come on… It saves a lot of arguing. :)
NO NO NO NO NO NO NO
You, sir, are worse than Hitler. A comma is not a terminator, it is a separator. Separators go between things, not after them.
To address the actual points:
1) If you have a problem with diff, fix diff.
wait, those two trivial issues are all the justification for something as abhorrent as trailing commas? GG.
How do you propose to fix diff? You’ll also have to fix patch, btw.