From: Louis J Scoras Date: 2006-10-07T08:50:35+09:00 Subject: Re: What is the reason for this syntax? On 10/6/06, Kevin Olemoh wrote: > David just because you like a given way of formatting does not mean > that everyone else should have to use it while they are creating > something even if they are working with you. I'm not sure what you are asking for in that case. How is a language supposed to figure out what you mean unless there is a specific construct it understands? There has to be a specific rules for syntax, even if it is a very simple one as with lisp. > The points you brought up are the reason people need to be using > comments in code not a reason for the language itself to try and > force a method of formatting onto its users. I can't count how many > times i have seen code that while well formatted does not make > nearly as much sense as it could because whoever wrote the code > did not put in enough comments if any at all. In the real world you > speak of people need to actually explain themselves when others > are going to be reading the code the formatting of the code is almost > entirely secondary. I'm going to have to disagree with you on this one. More often than not, copious comments are a bad code smell. It means that your code isn't readable enough or is hard to follow. Try to refactor it to make the logic cleaner instead. > (Are you sure you actually now what you are talking about what with > the overwhelming arrogance that you are exuding and all?) You don't think you're being a little arrogant as well? You come off as somebody that is just whining because things aren't the way you'd like them to be. Language designers are--generally speaking--a pretty intelligent group of people. Just because you don't like C's ternary operator doesn't mean it was a design mistake. > I should have said that the ternary operator is a conditional > expression that often serves the same or very simillar functinction as > a "traditional" if statement in c/c++ Actually it doesn't. The ternary operator ?: is very different from if/then in C because C, unlike Ruby, distinguishes between statements and expressions. > However my real point was that requiring things like that which can be > very difficult to read is a mistake on the part of the people creating > the syntax of a language and that point still stands. > The only person who is flaming anyone here is you my friend. This is purely an opinion. I find the construct to be sufficiently readable. -- Lou.