Homepage  • Privacy Policy & Imprint
extended fpc

Unleashed Pascal compiler

Unleashed Pascal (2026) is a fork of FreePascal and Lazarus that introduces modern language features — such as async/await, parallel loops, pattern matching, and string interpolation — as optional extensions, without compromising compatibility with old Pascal code.

Installer: ↗https://github.com/unleashedpascal/installer/releases

Licenses: Multiple open-source licenses (GPLv2, modified LGPL, MPL) inherited from the original FreePascal and Lazarus projects.

A Look Worth Taking: Unleashed Pascal

Unleashed Pascal can be installed and used completely independently of, and side by side with, FPC/Lazarus. That makes it safe to try out, since you can always fall back to your regular Lazarus setup at any time.

All extensions are strictly opt-in: every feature is switched on either through its own dedicated mode-switch or collectively via {$mode unleashed}. Existing code is left untouched either way.

The extensions fall into several broad categories. On the concurrency side, the project ships an async/await model in which a call spawns a background thread and await collects the result — with no event-loop concept involved at all. Alongside that comes a parallel for-loop that distributes loop bodies across a worker pool, lock/trylock blocks that set up and tear down critical sections automatically, and threadstatic variables for per-thread state without the classic threadvar declaration.

A second major focus is more compact syntax: inline variables with type inference, statement expressions (where if/case/try directly yield a value), a match statement as a modern replacement for simple case branching, anonymous tuple types with destructuring, string interpolation via $'...' literals, a step clause for for-loops, single-value initialization of multiple variables at once, and native 128-bit integers. Smaller helpers like SwapValues() and the Type() operator — Pascal's answer to decltype — round out this group.

For low-level, systems-style programming, a third block centers on memory layout: composable records with embed, union, and bitfields for porting C headers 1:1, C99-style flexible array members, static variables with program-wide lifetime, and scoped-cleanup mechanisms like defer and autofree that replace try/finally boilerplate. This is rounded out by a zeroinit modifier for deterministically initialized stack frames and a much more aggressive, genuinely enforced form of inlining.

In the realm of classes and generics, there are auto-properties that synthesize a backing field without any getter/setter code, along with nested generic methods and Delphi-style implicit generics that drop the generic/specialize keywords entirely.

For anyone who cares about control over the resulting binary, there's an option to strip RTTI type names, CLI switches for customizing embedded metadata, and directives for embedding files directly into the binary at compile time.

On the strings-and-literals front, multi-line string literals arrive in both backtick and triple-quote form, alongside a range of quality-of-life additions: consistent compound assignment operators, element-wise array comparisons, indexed and "lazy" labels for state machines, a loop counter that survives past break, and the more readable is not/not in negations.

Finally, the optimizer gains three extra tiers: automatic inlining of small routines from -O3 upward, a faster implementation of small FillChar/Move calls, and devirtualization of procedure variables whenever the compiler can prove that only one target address is possible.


Back  •  Scroll to Top  • Homepage