[[Niklaus Wirth]] (for Apple)<br/>[[Anders Hejlsberg]] (Borland)<ref name=\"InfoworldTechTalk\">{{cite magazine |last=Gibson |first=Steve |author-link=Steve Gibson (computer programmer) |date=May 8, 1989 |title=Borland and Microsoft Enter the Object-Oriented Pascal Ring |magazine=[[InfoWorld]] |page=28 |url=https://books.google.com/books?id=RzoEAAAAMBAJ&pg=PT27 |volume=11 |issue=19 |access-date=September 18, 2021 |archive-date=February 29, 2024 |archive-url=https://web.archive.org/web/20240229162502/https://books.google.com/books?id=RzoEAAAAMBAJ&pg=PT27#v=onepage&q&f=false |url-status=live }}</ref>"},"developers":{"wt":"Apple Computer (initial)<br/>Borland International<ref name=\"InfoworldTechTalk\"/>"},"released":{"wt":"{{Start date and age|1986}}"},"latest release version":{"wt":""},"latest release date":{"wt":""},"typing":{"wt":"[[Type system|Static and dynamic]] (dynamic typing through variants, ''array of const'', and [[Run-time type information|RTTI]]), [[Type system#Strong and weak typing|strong]], [[Type system#Safely and unsafely typed systems|safe]]"},"scope":{"wt":"[[Scope (computer science)|Lexical]] (static)"},"programming language":{"wt":""},"platform":{"wt":"[[ARM architecture family|ARM]], [[x86]], [[PowerPC]], [[ppc64]], [[SPARC]], [[MIPS architecture|MIPS]], [[Common Language Infrastructure|CLI]], [[Java (software platform)|Java]]"},"operating system":{"wt":""},"license":{"wt":""},"file ext":{"wt":"<code>.p</code>, <code>.pp</code>, <code>.pas</code>"},"file format":{"wt":"<!-- or: | file formats = -->"},"website":{"wt":"<!-- {{URL|www.example.com}} -->"},"implementations":{"wt":"[[Delphi (software)|Delphi]] ([[x86]], [[ARM architecture family|ARM]]), [[Free Pascal]] ([[x86]], [[PowerPC]], [[ppc64]], [[SPARC]], [[MIPS architecture|MIPS]], [[ARM architecture family|ARM]]), [[Oxygene (programming language)|Oxygene]] ([[Common Language Infrastructure|CLI]], [[Java (programming language)|Java]], Native [[Cocoa (API)|Cocoa]]), Smart Mobile Studio ([[JavaScript]])"},"dialects":{"wt":"Apple, [[Turbo Pascal]], [[Free Pascal]] (using '''objfpc''' or '''delphi''' mode), [[Delphi (software)|Delphi]], Delphi.NET, Delphi Web Script, [[PascalABC.NET]], [[Oxygene (programming language)|Oxygene]]"},"influenced by":{"wt":"[[Pascal (programming language)|Pascal]], [[Simula]], [[Smalltalk]]"},"influenced":{"wt":"[[C Sharp (programming language)|C#]], Genie, [[Java (programming language)|Java]], [[Nim (programming language)|Nim]], [[C/AL]]"}},"i":0}}]}'>
| Object Pascal |
|---|
| Paradigms | Imperative, structured, object-oriented, functional (Delphi dialect only), component-based, event-driven, generic |
|---|
| Family | Wirth Pascal |
|---|
| Designed by | Larry Tesler (Apple) Niklaus Wirth (for Apple) Anders Hejlsberg (Borland) |
|---|
| Developers | Apple Computer (initial) Borland International |
|---|
| First appeared | 1986;40 years ago (1986) |
|---|
| Typing discipline | Static and dynamic (dynamic typing through variants, array of const, and RTTI), strong, safe |
|---|
| Scope | Lexical (static) |
|---|
| Platform | ARM, x86, PowerPC, ppc64, SPARC, MIPS, CLI, Java |
|---|
| Filename extensions | .p, .pp, .pas |
|---|
| Major implementations |
|---|
| Delphi (x86, ARM), Free Pascal (x86, PowerPC, ppc64, SPARC, MIPS, ARM), Oxygene (CLI, Java, Native Cocoa), Smart Mobile Studio (JavaScript) |
| Dialects |
|---|
| Apple, Turbo Pascal, Free Pascal (using objfpc or delphi mode), Delphi, Delphi.NET, Delphi Web Script, PascalABC.NET, Oxygene |
| Influenced by |
|---|
| Pascal, Simula, Smalltalk |
| Influenced |
|---|
| C#, Genie, Java, Nim, C/AL |
Object Pascal is an extension to the programming language Pascal that provides object-oriented programming (OOP) features such as classes and methods.
The language was originally developed by Apple Computer as Clascal for the Lisa Workshop development system. As Lisa gave way to Macintosh, Apple collaborated with Niklaus Wirth, the author of Pascal, to develop an officially standardized version of Clascal. This was renamed Object Pascal. Through the mid-1980s, Object Pascal was the main programming language for early versions of the MacApp application framework. The language lost its place as the main development language on the Mac in 1991 with the release of the C++-based MacApp 3.0. Official support ended in 1996.
Symantec also developed a compiler for Object Pascal for their Think Pascal product, which could compile programs much faster than Apple's own Macintosh Programmer's Workshop (MPW). Symantec then developed the Think Class Library (TCL), based on MacApp concepts, which could be called from both Object Pascal and THINK C. The Think suite largely displaced MPW as the main development platform on the Mac in the late 1980s.
Symantec ported Object Pascal to the PC, and developed a similar object framework on that platform. In contrast to TCL, which eventually migrated to C++, the PC libraries remained mainly based on Pascal.
Borland added support for object-oriented programming to Turbo Pascal 5.5, which would eventually become the basis for the Object Pascal dialect used in Delphi created by Anders Hejlsberg. Delphi remained mainstream for business applications on the PC into the early 2000s, and was partly displaced in the 2000s with the introduction of the .NET Framework which included Hejlsberg's C#.
Because Delphi is a
trademark, compatible compilers continue using the name
Object Pascal.
Embarcadero Technologies, which purchased Delphi in 2008, sells the Delphi integrated development environment (IDE) that compiles the Delphi dialect of Object Pascal to Windows and macOS, iOS, Android and Web.
.NET support existed from Delphi 8 through Delphi 2005, 2006, and 2007, which now has been replaced by another language, Oxygene (see below), which is not fully backward-compatible.
The Oxygene language developed by RemObjects Software targets the Common Language Infrastructure, the Java Runtime Environment and Apple's Cocoa frameworks for iOS and macOS.
The open source Free Pascal project allows the language to be compiled for a wide range of operating systems, including Linux (32-bit, 64-bit), FreeBSD, Classic Mac OS, macOS, Solaris, Windows API (32, 64, CE), the ARM instruction set architecture (ISA), and several other hardware architectures. The first version of Free Pascal for the iPhone software development kit (SDK) 2.x was announced on January 17, 2009.
The Smart Pascal language targets ECMAScript–JavaScript and is used in Smart Mobile Studio, written by Jon Lennart Aasenden and published by Optimale Systemer (2012). The language greatly simplifies HTML5 development through object-oriented, and rapid application development (RAD) methods. Smart Pascal integrates tightly with established technologies such as node.js, Embarcadero DataSnap, and RemObjects SDK to produce high-performance client–server model web applications. The language allows easy creation of visual components and reusable libraries. The Smart Pascal dialect stems from the DWScript language, extended to better integrate with the JavaScript environment and libraries, such as asm sections which are plain JavaScript but have access to Pascal symbols, or external classes which map directly to prototypal JavaScript classes. Smart Pascal introduces true inheritance, classes, partial classes, interfaces, a virtual method table and many other advanced constructs which are not a part of JavaScript by default.
The Morfik Pascal language, developed by Morfik, targets Ajax-enabled Web applications. The compiler is built into the company's AppsBuilder IDE and allows Object Pascal code to be used in implementing code to execute in a browser or server. It uses the Free Pascal compiler to generate native binaries from Object Pascal.
The open source GNU Pascal compiler is available as a front-end to the GNU Compiler Collection, which implements the International Organization for Standardization (ISO) 7185 Pascal standard, and most of the ISO 10206 Extended Pascal standard.
Turbo51 is a free compiler to program Intel 8051 chips.
WDSibyl is an open source Delphi-like IDE and compiler available for Microsoft Windows and OS/2, and is a commercial Turbo Pascal compatible environment released by a company named Speedsoft that was later developed into a Delphi-like RAD environment named Sybil, and then open sourced under the GPL when that company closed down. Wolfgang Draxler (WD) now maintains the software. The compiler used seems to be located in a DLL and is not open-source.
Object Pascal compilers are available for a wide range of operating systems and architectures.
- Delphi is probably the best known compiler. It is the successor of the highly successful Borland Pascal and Turbo Pascal product line. It targets Windows 9x (Delphi 2007 and older), the Windows NT family, .NET Framework (Delphi 8, 2005, 2007), macOS (Delphi XE2 and later), iOS (Delphi XE2 and later, generating native binaries in XE4 and later), Android (Delphi XE5 and later, generating native binaries in XE5 and later). Support for .NET finally became a separate product known as Oxygene (see below).
- Free Pascal Compiler (FPC) is an open-source Object Pascal compiler that supports many Pascal dialects, including Turbo Pascal 7, Delphi, and others. Currently, FPC can generate code for IA-32, x86-64, PowerPC, SPARC, and ARM processors, and for several operating systems, including Microsoft Windows, Linux, FreeBSD, Classic Mac OS, and macOS (with an Xcode integration kit). Several separate projects exist to facilitate rapid application development with FPC, the most prominent one being Lazarus (IDE).
- GNU Pascal (a separately distributed part of the GNU Compiler Collection), while not formally aimed at the Delphi dialect of Pascal, does contain a Turbo Pascal compatibility mode, and is very slowly incorporating a few Delphi language features. It is unsuitable for recompiling large bodies of Delphi code directly, but is notable as having prolific support for operating systems and hardware architectures.
- Oxygene (formerly Chrome) is an Object Pascal compiler from RemObjects Software that integrates into Microsoft Visual Studio. It is also available as free command-line interface compiler that runs native on CLI. It is three compilers in one, each targeting a different platform: Echoes for .NET Framework, Mono, WinRT and Windows Phone 8, Cooper for JDK and Android, and Nougat for iOS and macOS.
- Borland Kylix was a Linux variant of Delphi which only targets Intel 32-bit Linux using the Qt library. It does not work out of the box with most modern Linux distributions.
- Virtual Pascal was a free 32-bit Turbo Pascal and Delphi compatible compiler for mainly OS/2 and Microsoft Windows. Later, it also received a DOS+ Extender and an experimental Linux cross-compiler. The compiler's development stopped at about the level of Delphi 2. In 2007, its official website ceased to operate, and further development ceased.
Pascal Script (formerly InnerFuse) and DWScript (Delphi Web Script) are open-source Object Pascal interpreters and scripting engines written in Delphi. They support subsets of Object Pascal. DWScript can also compile Object Pascal code into JavaScript code (Smart Pascal), and supports just-in-time compilation (JIT). Modern Pascal provides 3 different interpreters: a command-line interface (CLI), Apache Module (Celerity), and CodeRunner (node.js like solution able to handle different scripts per port), besides the ability to compile and protect a script's source code.
programObjectPascalExample;
type
THelloWorld=object
procedurePut;
end;
procedureTHelloWorld.Put;
begin
WriteLn('Hello, World!');
end;
var
HelloWorld:THelloWorld;{ allocated on the stack and can be used without explicit allocation. }
begin
HelloWorld.Put;
end.
Heap based allocation
edit
programObjectPascalExample;
type
THelloWorld=class
procedurePut;
end;
procedureTHelloWorld.Put;
begin
Writeln('Hello, World!');
end;
var
HelloWorld:THelloWorld;{ this is an implicit pointer }
begin
HelloWorld:=THelloWorld.Create;{ constructor returns a pointer to an object of type THelloWorld }
HelloWorld.Put;
HelloWorld.Free;{ this line deallocates the THelloWorld object pointed to by HelloWorld }
end.
Note that the object construct is still available in Delphi and Free Pascal.
- 1 2 Gibson, Steve (May 8, 1989). "Borland and Microsoft Enter the Object-Oriented Pascal Ring". InfoWorld. Vol. 11, no. 19. p. 28. Archived from the original on February 29, 2024. Retrieved September 18, 2021.
- ↑ Tesler, Larry (February 4, 1985). "Object Pascal for the Macintosh" (PDF). Retrieved March 13, 2025.
- ↑ Arnold, Brian (February 1996). "MacApp 2 for PowerPC in Object Pascal". MacTech. Vol. 12, no. 2. pp. 25–32.
- ↑ Aasenden, Jon Lennart (May 18, 2012). A Smart Book. Leanpub. Archived from the original on May 25, 2013. Retrieved June 19, 2013.
- ↑ "EDM/2: WDSibyl". Archived from the original on March 24, 2021. Retrieved July 14, 2026.
- ↑
"Modern Pascal". Archived from the original on December 11, 2018. Retrieved October 22, 2018.
- ↑ Lists: Alphabetical
- Categorical
- Generational
- Non-English-based