News for hackers. Stuff that matters.
Re:A half-hour to learn Rust by gameswithgo on Saturday February 29, 2020 @08:05AM (#22450339)
The C approach makes the compiler much more complex, and introduces extra typing in other language constructs. (like parens around if statements) This is why many newer languages do something more like the Rust way. Overall it is simpler for programmer and compiler.
Re:A half-hour to learn Rust by dmit on Saturday February 29, 2020 @08:56AM (#22450542)
Pretty much. The mere existence of cdecl(1) says a lot about the simplicity of C's type declaration syntax.
Re:A half-hour to learn Rust by jstimpfle on Saturday February 29, 2020 @12:04PM (#22451530)
It's unfortunate that the simple (and easy) underlying principles are not well known. See my other comment.

The bigger reason why recent languages have different declaration syntax is to avoid the need to carry a symbol table during parsing, and to avoid the need to parse all files serially instead of independently. Because to recognize a declaration the parser has to know which words correspond to types in the current scope.

Re:A half-hour to learn Rust by jstimpfle on Saturday February 29, 2020 @12:36PM (#22451754)
I don't think parentheses around if-conditions are related to C variable declarations (if that's what you were saying), and I think it's fair to say that C's syntactical terseness is unmatched.

The parentheses are required to separate the condition from the following conditional statement.