Remix.run Logo
init1 3 hours ago

Verbosity is a feature not a bug. Programming is a human activity and thus should use human language and avoid encoded forms that require decoding to understand. The use of abbreviations should be avoided as it obsfucates the meaning and purpose of code from a reader.

GhosT078 a few seconds ago | parent | next [-]

I agree. I've never understood or accepted the claim that Ada is verbose. It's simply clear and expressive. If there were some alternative concise syntax for "Ada" then I would not want to use it (because it would not be Ada).

This was proposed, as a joke, some years ago: https://www.adacore.com/blog/a-modern-syntax-for-ada

This is an old but good article on the topic: https://www.embedded.com/expressive-vs-permissive-languages-... Note that SPARK has changed significantly since this was written.

adrian_b 2 hours ago | parent | prev | next [-]

The programming community is strongly divided between those who believe that verbosity is a feature and not a bug and those who believe that verbosity is a bug and not a feature.

A reconciliation between these 2 camps appears impossible. Therefore I think that the ideal programming language should admit 2 equivalent representations, to satisfy both kinds of people.

The pro-verbose camp argues that they cannot remember many different symbols, so they prefer long texts using keywords resembling a natural language.

The anti-verbose camp, to which I belong, argues that they can remember mathematical symbols and other such symbols, and that for them it is much more important to see on a screen an amount of program as big as possible, to avoid the need of moving back and forth through the source text.

Both camps claim that what they support is the way to make the easiest to read source programs, and this must indeed be true for themselves.

So it seems that it is impossible to choose rules that can ensure the best readability for all program readers or maintainers.

My opinion is that source programs must not be stored and edited as text, but as abstract syntax trees. The program source editors and viewers should implement multiple kinds of views for the same source program, according to the taste of the user.

init1 2 hours ago | parent [-]

It is not that I cannot remember the symbols - I don't want to; I want the language to plainly explain itself to me. Furthermore every language has it's own set of unique symbols. For new readers to a language you first have to familiarize yourself with the new symbols. I remember my first few times reading rust... It still makes my head spin. I had to keep looking up what everything did. If the plain keyword doesn't directly tell you what it's doing at least it hints at it.

To be clear Ada specifically talks about all this in the Ada reference manual in the Introduction. It was specifically designed for readers as opposed to writers for very good reasons and it explains why. It's exactly one of the features other languages will eventually learn they need and will independently "discover" some number of years in the future.

zozbot234 2 hours ago | parent [-]

Rust has a complex semantics, not a complicated syntax. The syntax was explicitly chosen to be quite C/C++ like while streamlining some aspects of it (e.g. the terrible type-ascription syntax, replaced with `let name: type`).

init1 an hour ago | parent [-]

In my opinion it has both complicated and terrible syntax that it inherited and extended from c++ and complicated semantics.

zozbot234 2 hours ago | parent | prev [-]

Verbosity is a feature for small self-contained programs, and a bug for everything else. As long as you're using recognizable mnemonics and not just ASCII line noise or weird unreadable runes (as with APL) terseness is no obstacle at all for a good programmer.