top | item 34268901

(no title)

jonasenordin | 3 years ago

Good observations. Actually more important than it looks, I think. All those little helpful things.

Also worth discussing: micro-misfeatures to be avoided when designing new languages. Maybe non-micro-misfeatures, ie the lack thereof, can be considered a microfeature. Like, for example, uniformity.

And I just have to trot out my favorite example: Java import statements do not allow keywords and numbers in package names. So we can't put our Java source code in folders named 'import', 'long', or in paths like '2023/01/'. Great. For no good-enough reason - the syntax would actually be cleaner with a separate package name syntax. (BTW, this could be fixed, I think.)

discuss

order

lamontcg|3 years ago

Ruby having anonymous functions being defined like { |args| <whatever> } and for no arguments you can drop the || entirely. Rust's |args| { <whatever> } with || { <whatever> } being mandatory for no args removes the ambiguity in parsing.