2012/7/20 Ivan Enderlin @ Hoa <ivan.ender...@hoa-project.net>: > On 20/07/12 15:32, Alex Aulbach wrote: >> If you use try/catch that much, that you begin to think about the >> syntax, you have an architecture- or design-problem. > > Not sure about that. First, it was an example. Second, it happens more often > than you think. For example, if you're writing a dispatcher (i.e. redirect > some data to some callables), you will want to catch exception as early as > possible.
And you misunderstood me: My first thought of removing bracelets was, that someone could need this, because he has hundreds of try/catch-blocks and just want to spare some typing. My thinking is: If someone needs that much try/catch that he begins to think about syntax, he has definitely another problem (architecture/design). >This is not an architecture- or design-issue, this happens > sometimes when you code. It's always so, but it's not a reason for another syntax. :) > And I would like to point that this is not the topic. The topic is > consistency in PHP syntax (restricted to control structures and > brackets/braces). No, that's exactly the point. :) The reason why we have different syntaxes is, that it was introduced in PHP/FI, about 16 yreas ago. I cannot remember the exact timings, but Rasmus experimented a lot with the syntax and everybody was glad, when the C-syntax has been implemented - but the old syntax-stuff remained and was quite buggy and very obfuscating. This was fixed with PHP3. That's why we have syntaxes without bracelets, everybody liked it, because we could say "haha, you perl-guys, you C-junkies, we've more ways to program an if". That's about 16 (?) year ago and perhaps I mixed it a lttle bit up. But nowadays it's no question, that brackets are good. But at that time continental-European programmers tend not using bracelets, because they are so difficult to type. :) In other words: You want to introduce something, which we are glad not to need anymore. :) -- Alex Aulbach -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php