Slashdot Mirror


Free Pascal 2.0 Released

Eugenia writes "After five years of development, Free Pascal 2.0 is ready and it includes support for many architectures and OSes. It now has threading support, interfaces, widestring and better Delphi support among many other new features. OSNews posted an article introducing the updated GPL compiler." petermgreen adds a list of some of the major changes since the last stable release: "Much better support for Delphi language features (especailly method pointers); more supported CPUs (AMD64, SPARC, PPC (32 bit), ARM) and platforms (Mac OS classic, Mac OS X, MorphOS, Novell Netware); a new and better structured Unix RTL Threading support; and a large number of internal changes including rewriting large parts of the compiler to make it more maintainable and easier to port to new architectures," and notes that "Visual parts of Delphi are being handled by a seperate project known as lazarus, which has not yet reached 1.0 but should do so fairly soon."

17 of 451 comments (clear)

  1. awesome by Prophetic_Truth · · Score: 3, Insightful

    the more development tools, the better

    --
    time is a perception of a being's consciousness
    time is your 6th sense, the wierd ones are 7+
    1. Re:awesome by Nutria · · Score: 4, Insightful

      what would be a good reason to choose Pascal over any other given language?

      Since it's a B&D language, you won't get buffer overflow bugs & exploits. (In and of itself, that's a mighty good reason to use Anything But C.)

      Since it (well, Turbo Pascal did, so I guess Delphi does, too) knows how long strings are, there's no need for that silly necessity for null-term strings, and all the consequent bugs.

      But... since it's a B&D language, there will be other gotchas to struggle with.

      --
      "I don't know, therefore Aliens" Wafflebox1
  2. Out of curiousity... by winkydink · · Score: 5, Insightful

    and not meant in a trollish way, but what is Pascal used for these days? What are it's inherent advantages over other languages?

    --

    "I'd rather be a lightning rod than a seismometer." -Ken Kesey

    1. Re:Out of curiousity... by NetNifty · · Score: 5, Insightful

      First things that come to mind are prototyping and education - I'm sure I'm not the only /.er who was taught Pascal at school.

    2. Re:Out of curiousity... by rainman_bc · · Score: 4, Insightful

      Well it's got the strength of C and the readability of Delphi.

      Might not be as many job opportunities out there for a Free Pascal programmer, but for some who want to walk down memory lane...

      --
      09 F9 11 02 9D 74 E3 5B D8 41 56 C5 63 56 88 C0
    3. Re:Out of curiousity... by FidelCatsro · · Score: 2, Insightful

      debugging , pascal really strongly promotes clean codding . I can generaly pick a piece of pascal code and understand it very quickly as opposed to c or c++ which is more free form ( i enjoy to code more in C but i much preferreading others code in pascal)

      --
      The only things certain in war are Propaganda and Death. You can never be sure which is which though
    4. Re:Out of curiousity... by KiloByte · · Score: 4, Insightful

      Exactly, Pascal is a lot, lot better when it comes to writing correct code. It's faster to hack around in C, Perl or Python, but when it comes to debugging, you can't really beat Pascal.

      Too bad, the lack of support killed it. The ISO version was absolutely unusable, as described in many essays ("Pascal considered harmful", etc). Turbo Pascal was a powerful tool, but it's lost in the mists of the past now.

      GPC can't be considered anything but sabotage (its developers intentionally break things like record types and stick with the broken ISO "standard"), and Delphi went into an insane streak of badly-designed hacks.

      Pascal is probably the best language for learning algorithms theory, too. Unfortunately, I would say that it's too late to try to revive it. There is too much C code to make the switch worthwhile to a language that is pretty much an equivalent of C.

      --
      The creatures outside looked from Alt-Right to Antifa; but already it was impossible to say which was which.
    5. Re:Out of curiousity... by apankrat · · Score: 2, Insightful

      Well it's got the strength of C ..

      I have no idea what the strength of the language is, but I do know that Pascal is a Context Free Grammar language. That what gives it an incredible compilation speed, but it also automatically means that it has very basic semantics compared to other languages in general and to C in particular.

      --
      3.243F6A8885A308D313
    6. Re:Out of curiousity... by dtfinch · · Score: 2, Insightful

      The Dev-C++ IDE is written in Pascal (Delphi), as unusual as that sounds. A whole lot of Windows software is written using Delphi, especially shareware, it's just not obvious to the user. Trying to do GUI development using Visual C++ was a nightmare, leaving Delphi as the only choice if you wanted easy RAD development and natively compiled code in the years before VB5 and VS.Net.

    7. Re:Out of curiousity... by Siener · · Score: 4, Insightful

      First, I have to say I'm a big fan of Delphi. I've done dozens of projects with it in the last 10 years.

      I'm a big fan of Delphi too. I have experience in using lots of other development environments for Windows, and Delphi is simply THE best possible tool for Windows development - especially if you are working in a big development team.

      I really believe that once a programmer knows the ins/outs of Object Pascal (the language used by Delphi) he/she can be more productive than in any other language for Windows. Unfortunately many developers never get to that stage. This is of course a problem not exclusive to Delphi - It seems like in many courses for "Visual" languages all the time is spent on learning how to make nice looking forms, and not enough on the core language and proper OO programming - be it Basic, c# or whatever - but I digress.

      Another interesting fact - Java may look like C++, but if you look a bit deeper it has a lot more in common with Object Pascal. E.g. All objects are references, there is a single base class from which all other classes are derived etc. I've seen that because of this it's much easier for a Delphi developer to become a good Java developer than it is for a C++ developer to become one. A new syntax is easy to learn - a new programming philosophy is harder.

      The only reason that the use of Delphi has not become more common seems to be Borland's bad marketing. I once read a editorial in a Delphi magazine where the editor lamented about this. His conclusion was something like this: "It seems that Borland decided let's develop the best tool out there for Windows development, and then keep it a secret"

  3. Re:Ahh Pascal by man_ls · · Score: 2, Insightful

    In such a case, x and y *are* descriptive variable names :p

  4. Easy to shoot your own foot w/Pascal by xv4n · · Score: 2, Insightful

    I remember in the early 90's making a code review on someone's pascal code. His program was underperforming running very slow. I found out he was passing a typedef'ed char array of 255 characters as value to some function. Pushing the entire array into the stack on every function call was killing performance. After changing that to pass the array as a reference the app performed drastically better. And that was just by adding 'var' in front of the parameter argument.

    1. Re:Easy to shoot your own foot w/Pascal by cnettel · · Score: 2, Insightful
      I'm not very sure if I prefer the C notion that passing an array is actually always passing down a reference to it. Or that objects, but not primitives, are always passed by reference in Java. Try to teach a class what the stack is and that parameters are just funky names you give to copies of your data, when so much of it is still treated like they weren't copies at all.

      In C (and even more so in Java) you shoot yourself in the foot in the foot by accident, you get the wrong results from what a naive interpretation of the syntax from a general computer science standpoint could indicate. In Pascal, you get what you asked for. It's stupid, but it is what you asked for.

  5. Education by jd · · Score: 5, Insightful
    Pascal is one of the best educational programming languages out there. C is much more powerful, but is also much more lax - you can get away with really lousy coding and it often works. Ada is too cumbersome to have any practical educational value. COBOL should be taken away from academics, along with any sharp objects.


    Pascal offers a good balance, forcing you to think about what you are doing, not merely how you are going to go about doing it. A lax style is often picked out by the compiler, and errors are often easier to see and correct.


    The greatest advantage of Pascal, though, is that it is NOT used much in the workplace. This may seem odd, for something you're going to teach with, but think about it. It means that most people will be starting off fresh, rather than with bad habits, and means that you are learning about programming, rather than learning about some specific job. Jobs come and go, but software engineering will always be there.


    Learning a skill for a specific job is only useful as long as that job is around. For example, if you learn Visual Basic today, you're market fodder if those jobs run dry by the .NET and C# rush that is going on. If you learn .NET and C#, you're dead in the water when the next rush comes along. You need to know what lies behind the skills, the generic stuff, because you can transfer those skills any time you like. A good coder can always pick up new languages. I know something like 20. But if you're locked into a language, you've got to learn anything new from scratch. You've nothing to build in.

    --
    It's a small world and it smells funny; I'd buy another if it wasn't for the money; Take back what I paid (SoM)
  6. Re:Why bother? by Anonymous Coward · · Score: 3, Insightful

    Because the Delphi dialect of pascal *is* such a good language, because FreePascal supports Delphi and because Borland's continuing support for Delphi (and certainly Kylix) is highly suspect at best.

    Actually Borland's future is rather uncertain these days let alone their Delphi product support, so an open source cross-platform alternative for Delphi developers is most welcome addition to the FOSS landscape.

  7. Re:missed opportunity by marcovje · · Score: 2, Insightful


    People that get caught up in pissing contests typically don't reach 2.0

  8. Re:Teaching vs. Industrial Use by barrkel · · Score: 2, Insightful

    If you'd used Delphi, you'd realize you were wrong. Delphi's class libraries can teach one an awful lot about OO design in an unmanaged world; how to create a useful design-time architecture in an object model; how a good PME (properties, methods, events) environment should look. Also, there's some features in Pascal that aren't really replicated in other modern imperative languages apart from Ada (subrange types, sets, truly typesafe enums).

    Before Anders Heiljsberg (the guy behind Delphi) moved on and created C#, Delphi was the source of the One True Way of UI programming on Windows.

    You talk about Java's threading support blowing C/C++ out of the water. It's interesting: Delphi has extremely easy to use threads.

    However, I do agree that it's important that more people learn the basics of functional languages, their semantics and implementation details (in terms of compilation and runtime libraries). I'd also throw in declarative rule-based languages: learn something like Prolog as well. Finally, one cannot be a truly well-rounded programmer without implementing at least one compiler from scratch.

    But that's only my opinion.