Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
Advantages of the Free Pascal Compiler (freepascal.org)
14 points by hochmartinez on Feb 7, 2024 | hide | past | favorite | 7 comments


I'm not sure about the value of this, as it seems to have been written in another time and not updated to reflect current realities.

This is supported by the website having (C) 1993-2023. And ideed, a lot of the points would make sense in the mid-90s landscape. Moreover, the only change to the list since its first snapshot in the Internet Archive in 2006 is the addition of the "High speed, low memory" paragraph. But there's no mention if there's parity for the features that cause the other languages to be slower/more memory hungry, or clarification if "fast" refers to the produced binaries or the language itself.

While I have nothing again Pascal/Free Pascal, I'm not sure why this would be upvoted, or even posted in the first place.


That's true -- things like smart linking are completely standard today. The earliest version of the page I can find is from 2006 [1] with very similar content.

That said, things like "no makefiles" are neat, especially in today's world of complex build systems. If it was written today maybe it would say "No Gradle."

[1] https://web.archive.org/web/20061114051555/https://www.freep...


The future plans include improving OS/2 support.


At least OS/2 is still on their list of supported operating systems, so there might still be someone working on improving OS/2 support? DOS support seems pretty good and well-maintained at least, but I have barely tried to compile (or cross-compile) for other platforms.

"Free Pascal is a mature, versatile, open source Pascal compiler. It can target many processor architectures: Intel x86 (16 and 32 bit), AMD64/x86-64, PowerPC, PowerPC64, SPARC, SPARC64, ARM, AArch64, MIPS, Motorola 68k, AVR, and the JVM. Supported operating systems include Windows (16/32/64 bit, CE, and native NT), Linux, Mac OS X/iOS/iPhoneSimulator/Darwin, FreeBSD and other BSD flavors, DOS (16 bit, or 32 bit DPMI), OS/2, AIX, Android, Haiku, Nintendo GBA/DS/Wii, AmigaOS, MorphOS, AROS, Atari TOS, and various embedded platforms. Additionally, support for RISC-V (32/64), Xtensa, and Z80 architectures, and for the LLVM compiler infrastructure is available in the development version. Additionally, the Free Pascal team maintains a transpiler for pascal to Javascript called pas2js".


Say what you want about the merits of the Pascal language itself, but the Free Pascal compiler paired with the Lazarus IDE and toolkit is still one of the most productive ways to create performant, cross platform desktop applications.


Agree 100%. Went down the rabbit hole of reasonable cross platform UI frameworks and for me Lazarus/FPC won


Quote: "Each unit has it's own identifiers In Pascal you never need to worry about polluting the namespace, like in C where an identifier needs to be unique accross the entire program. No, in Pascal each unit gets it's own namespace and that's very relaxed."

While this is true, you can export the same function/procedure name from 2 different units- and that can bite you in the rear. The way it works is that the last one listed in the "uses" clause ("include" equivalent of Pascal) is the one that has priority. If you want to use the function from the first one you need to actually go use the full identifier of the unit in order to call the first one (unit1name.samefunctionname(blabla parameters). This is notoriously a big bug with 3rd party vendors who want to expand the capability of the general units (looking at you DevExpress) by using the same units name. While I get the over all advantages of doing this on purpose, it also pisses me when I really need the basic one instead of the "enhanced" one.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: