Note for people who don't know much about FreePascal. It is a full-featured and very fast compiler. The resulting program is a rival for the best output of C/CPP compilers. It can be used in the style of simpler languages like Go and is almost as safe as Rust in a much faster manner. It has a great but old-looking IDE, Lazarus. It has been under active development for decades and is used for proper projects like:<p><a href="https://dadroit.com/" rel="nofollow">https://dadroit.com/</a>
<a href="https://peazip.github.io/" rel="nofollow">https://peazip.github.io/</a>
<a href="https://cudatext.github.io/" rel="nofollow">https://cudatext.github.io/</a>
<a href="https://lazpaint.github.io/" rel="nofollow">https://lazpaint.github.io/</a><p>As far as I know, there is no toolkit out there that lets you make fine looking applications for multiple platforms with proper speed.<p>The old Pascal you may know is not the new Pascal. The development of Pascal is mostly focused on ease of development while maintaining low-level programming and backward compatibility. It looks old on its face, but it is young at heart.<p>I recommend starting with Lazarus, <a href="https://www.lazarus-ide.org" rel="nofollow">https://www.lazarus-ide.org</a>, a much lighter IDE compared to so-called light projects like VSCode, with many more features and components to play with.<p>Friendly word: don't let the comments with outdated information make you miss a great and fun tool.
Pascal gets an underserved bad reputation.
I am showing my age but Turbo Pascal was (is) great.
Extensions from Turbo and Delphi Object Pascal is great as well.<p>I hate the insane pricing Embarcado has imposed on Delphi.
They have had cross platform GUIs in Delphi for a long time.
Something for some reason other tools struggle and mostly fail to do.<p>I have not been able to "sell" it to clients mostly due to price.
A peculiar aspect of Lazarus (Free Pascal's Delphi-like IDE) is that it either cross-compiles for other architectures or can run itself on them, therefore generating native GUI software that runs immediately on the target platform.
That is, you can develop ARM executables on a Raspberry PI using Lazarus running on the Pi itself.
I would also suggest to take a look at FPCUpDeluxe, an installer that does all the tedious job of dealing with dependencies for installing FPC, Lazarus and a great number of modules and components.<p><a href="https://wiki.freepascal.org/Lazarus_on_Raspberry_Pi" rel="nofollow">https://wiki.freepascal.org/Lazarus_on_Raspberry_Pi</a><p><a href="https://wiki.lazarus.freepascal.org/fpcupdeluxe" rel="nofollow">https://wiki.lazarus.freepascal.org/fpcupdeluxe</a><p>A personal dream: having something like Lazarus that works with other languages too; that would likely become a game changer for desktop apps development.
I think the popularity of pascal has something to with Modula-2 (the successor of Pascal invented by Wirth) having been recently included as an officially supported language in gcc alongside Rust. I tried lazarus again, I was amazed. It is as simple as using VB6 for creating quick GUIs that run everywhere. Turbopascal is blazingly fast, produces efficient and small binaries.<p>Pascal also has libraries for nearly everything, check awesome pascal for a list of actively maintained third party libraries:
<a href="https://github.com/Fr0sT-Brutal/awesome-pascal">https://github.com/Fr0sT-Brutal/awesome-pascal</a><p>I feel like pascal is a hidden gem.
I used to be a hard Delphi/Pascal guy and still think it is much better than C for it's strong typing and overall "squareness". But I'd have a hard time going back to it nowadays. The 'var' section, magic "Result" variable and begin/end pairs are just from another age.<p>Programming languages have advanced _a lot_ since Pascal was created. It's core principles remain valid (safety by default, readability, flexibility). But the feedback loop between language design and actual usage is much tighter thanks to the Internet and open source.<p>Some things I still miss from my Delphi days are the language-level enumsets, near-instant compilation and RAD tooling (GUI builder).
Pascal killed my interest in programming for a while as it was force fed in both high school and earlier collage years. Reflecting back, it was the pessimistic approach to teaching of just pushing math problems via programming.
There is also this <a href="https://castle-engine.io/modern_pascal" rel="nofollow">https://castle-engine.io/modern_pascal</a>
Personally I read the programmer manual for FP. You can do both Object Pascal OOP and Delphi OOP.<p>Wild. Also nice units for doing mmap and all libc stuff. I really ought to finish learning Pascal and actually write something in it. Not a bad language.
When I looked into learning Free Pascal (not <i>that</i> many years ago) it seemed to me like Ada was the more well-developed, actively used language of that sort of heritage.<p>Have any of you used both languages? What made you stick with Free Pascal instead?<p>(To be clear, I'm interested in a comparison that goes beyond the price point of the commercial compilers, which is a tired subject at this point.)
Don't download the bundled Free Pascal and Lazarus distributions from this site, they're very outdated. Just get the normal releases from the actual Free Pascal and Lazarus sites which are linked at the top of the page. Lazarus comes with Free Pascal bundled by default anyways, so you don't need to grab the compiler separately if using Lazarus.
Some recent personal projects with laz and fp got me pretty interested in it.<p>I have nothing impressive to show for my work except for a lot of retro-pride when I type in e.g. the snippet which triggers the Pascal program which tells me how old I am. With some bells and maybe a couple whistles.<p>I was surprised to learn that there was Pascal for the C64, which I thought was more of a "BASIC or bare metal" system.<p>I too was a victim of the great AP Pascal force-feed in my HS comp. sci. class...but fortunately at the same time there were demoscene programmers around the world blowing my mind with Pascal programs and it seemed like there were new projects to appreciate online (BBS) every day after school.<p>To whit: Someday I would like to write a Pascal raytracer that tells me how old I am, with emoji output, since my other ride is a text editor. (And if you don't like my driving, get off the sidewalk!)
There are some things that Lazarus/Free Pascal does right:<p>- It has the most sane strings you'll ever see, you don't have to allocate them, and they can hold gigabytes of text.<p>- You'll never confuse equality tests = with assignment :=<p>- It's case insensitive<p>- It doesn't do macros<p>- It is one of the fastest compilers available<p>- It is one of the best GUI builders available<p>Things it doesn't do right<p>- Begin/End seems verbose to some people<p>- Other "standard" pascal systems gave it a bad name<p>- Historically, Borland et al, priced people out of their products and killed off a loyal use base.
Back when I learned computing, I had an old Apple ][+ with a Z80 card. There were only a few choices to program it. Apple and Z80 BASIC, Apple Logo, 6502 assembly (I did not have access to a Z80 assembler) and UCSD Pascal.<p>Pascal was awesome. So much better than the others. It really launched my interest in coding once it clicked.<p>I remember discovering that the early Apple game Wizardry was written in it one day when I was hacking around with it.
I still remember that the thesis of a fellow student back in the university 20 years ago was to create an educational version of Pascal called... "Paschool".<p>I laugh out loud when I remember it, definitely the programming language with the most funny/catchy name ever!
Since this is a pretty general thread about Pascal, shout out to Castle Game Engine:<p><a href="https://castle-engine.io/" rel="nofollow">https://castle-engine.io/</a>
This website, is a collection of cool samples and sources. Check <a href="https://www.getlazarus.org/learn/tutorials/examples/" rel="nofollow">https://www.getlazarus.org/learn/tutorials/examples/</a> for many cool projects and the author has many nice projects including <a href="https://github.com/sysrpl/Tiny.Sim">https://github.com/sysrpl/Tiny.Sim</a>
Coincidentally i tried to install Lazarus yesterday and hit issue after issue, two being some missing dependencies, which were items that I found in the documentation to be downloads as well. It then complained about lack of gdb, which I do understand (on an older Macos here) but it did occur to me, if you know it is needed, why not include it in the download?<p>Cut a long story short, Ive installed Dr Racket today and working through the tutorials.