These are often just forced aesthetic views with no proper backing. Another way to instead look at braces is initialization syntax sugar, where the values enclosed in braces are processed in total to construct an object. For compound types, those values would be field values; for arrays, element values; for primitive values, their direct initializers.
Everyone can keep their own style preferences but most of these hard lines are just people (who often don’t like the language to begin with) making weird dictates with vague reasoning.
View all comments
Show parent comment
2
u/Big-Rub9545 15d ago
These are often just forced aesthetic views with no proper backing. Another way to instead look at braces is initialization syntax sugar, where the values enclosed in braces are processed in total to construct an object. For compound types, those values would be field values; for arrays, element values; for primitive values, their direct initializers.
Everyone can keep their own style preferences but most of these hard lines are just people (who often don’t like the language to begin with) making weird dictates with vague reasoning.