Castalia do not like my if/then/else syntax


Castalia do not like my if/then/else syntax

Comments

  1. Alternatively you an use CN Pack's corresponding feature: http://i.stack.imgur.com/DHq1f.png

    ReplyDelete
  2. The amazing thing is that you have to pay for Castalia, while CN Pack was always free, open source and have way better quality. Even you can contribute to the project, as an open source project is intended to be.

    I start to see a pattern, too much people is paying for crap nowdays and supporting the wrong developers... sigh!

    ReplyDelete
  3. Michael Thuma I remember to have tried Castalia. I was disapointed, then found CN Pack and fall in love with it, it has been satifying since first day, no complains. I think Castalia has to much hype for what it cost and what it does.

    ReplyDelete
  4. To be fair,I don't like your if/then/else syntax either.

    ReplyDelete
  5. Steven Camilleri I can understand, it's not perfect, but I don't like any other way to write it.

    ReplyDelete
  6. I have to agree with Castalia on this one. It's difficult to read code that's formatted like this. :)

    ReplyDelete
  7. My model is
    if condition
    then begin
    end
    else if another condition
    then begin
    end
    else begin
    end;
    and variations on that - which ever reads the best.

    ReplyDelete
  8. We all have our preferences. I like the keywords that influence the flow to be aligned. When I find an "end", it's guaranteed to have whitespace above it until the keyword that started it.

    That way, I only have to scan white space and some first words on a line, without having to scan the rest of the code.

    So yes, my code uses more lines, but when i read it, I can skip through irrelevant parts much faster, because i have less code to read.

    I compensate for the extra lines by using a large monitor, a high resolution and a small font. :)

    ReplyDelete
  9. anyway, the code readability is above all a matter of habit. At the time I was coding with Turbo Pascal my source was very compact to fit on a 80x25 screen and I found it very readable at that time. Now I tend to space out my code and I find it also more readable. I also stopped using uppercase initial on keywords which I now find indigestible :)

    "end else begin" is a vestige of that old time..it took me a lot of time to place begin under if ;)

    ReplyDelete
  10. Fortunately Pascal is not very strict with spaces and indentation. My form of If...Then...Else is more like:

    if then begin
    end
    else begin
    end;

    And my right margin is very wide too (132), because of wide screen has no sense to stick to 80 columns.

    ReplyDelete

Post a Comment