Take the 2-minute tour ×
Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. It's 100% free, no registration required.

I don't think Objective C was in use from the beginning of Apple hardware development. What languages did app developers use for the earlier Apple computers, such as Apple II or Mac Classic?

share|improve this question
add comment

4 Answers

up vote 32 down vote accepted

In 1985 Larry Tesler developed a Pascal flavour for Apple, Object Pascal, that became the standard language for System 6. It was based on Clascal, a 1983 Pascal variant for the Lisa, also developed at Apple.

Object Pascal was used in MacApp, Apple's primary application framework at the time. MacApp 3.0, released in 1991, was re-written in C++ and Apple subsequently dropped support for Object Pascal in favour of C++ when they moved from Motorola's 68K chips to PowerPC.

Borland's Object Pascal, that today lives on as Embarcadero Delphi, started out in 1986 as a set of extensions to Turbo Pascal, that were intended to be similar to Apple's Object Pascal. Niklaus Wirth, Pascal's originator, was consulted by both Apple and Borland for their respective variants.

Conversely, Objective C was NeXTSTEP's main language and was introduced at Apple only after they purchased NeXT in 1996.

share|improve this answer
3  
Good answer, but since it's the accepted one you should really add mentions for both Pascal and C. From the very beginning, the Mac Toolbox and OS used Pascal calling conventions and was documented largely with Pascal. There were a number of Pascal compilers available; the most popular was probably Lightspeed Pascal. C was also popular from the beginning, and by the time Think purchased both Lightspeed C and Lightspeed Pascal, C was probably the "standard" choice for indie developers. Also, metrowerks C++ and PowerPlant deserve a mention. –  Caleb Dec 3 '12 at 7:01
    
This answer seems to lean more towards what frameworks were used for development as opposed to which languages. The OP's question was about Objective-C (the language), not Cocoa (the framework), but the answer has a paragraph on MacApp (the framework) and little mention of C/C++ other than the fact that MacApp was ported to it. A lot of applications were written directly against the Mac OS Toolbox in Pascal, C, and/or C++. Good answer otherwise, but needs broader coverage of C/C++. –  morgant Dec 3 '12 at 18:02
add comment

The Apple ][ was generally programmed in either BASIC or 6502 machine code.

The Lisa was generally programmed in Pascal.

Early Macintosh apps were written in Pascal, first on the Lisa and later on the Mac itself.

Think Pascal was the most popular development environment for a time and then Think C. Think C had lightweight objects, sometimes referred to as C+-, and later C++. It also had its own class library called, appropriately enough, the Think Class Library.

MPW from Apple was also popular since it allowed you to mix languages (generally Pascal, C, C++, and assembler) and script builds similar to a unix environment, though the syntax was very different.

MacApp was written in Object Pascal, and as someone said, later moved to C++. With the move to PowerPC systems, many programmers switched to Metrowerks CodeWarrior as a development environment and its C++ class library, PowerPlant.

Objective-C was used at NeXT and then for Mac OS X, although Mac OS X applications could also be written in C/C++ via Apple's "Carbon" API. These days most Mac and iOS apps are written in Cocoa/Obj-C, although many have C or C++ libraries underneath.

share|improve this answer
1  
The Apple /// was also programmed in Pascal (ISTR there was also a variant of BASIC available). I think we used the UCSD pSystem, but there was an Apple Pascal compiler also. –  TMN Dec 3 '12 at 20:12
    
The Apple /// was the only Apple computer I never programmed. I do remember a UCSD pSystem for the Apple ][ as well, but I don't think there was a good way to distribute apps written in it. –  EricS Dec 4 '12 at 2:49
add comment

The standard language of Mac OS Classic was Pascal. The OS's API documentation was all written for Pascal, and as much of the OS as was not written in hand-optimized ASM was written in Pascal.

After transitioning to the PowerPC architecture, they rewrote the OS in C++, accompanied by a very noticeable decrease in system stability, which will not be surprising to anyone familiar with Pascal and C++. API documentation continued to be written primarily for Pascal, though, until Steve Jobs came back and started trying to force Objective-C down everyone's throats.

share|improve this answer
4  
"accompanied by a very noticeable decrease in system stability, which will not be surprising to anyone familiar with Pascal and C++": Having worked with both languages I can easily believe this. I still sometimes wonder why Pascal (or any object-oriented extension thereof) is currently less popular than C++: after all, development and bug fixing time costs money. Maybe it is because Pascal failed to build a strong and compact community similar to that of C++. –  Giorgio Dec 2 '12 at 14:18
3  
Pascal failed mostly because there was no standard (well the standard came too late) and the common subset was too restrictive (you had to rely on extensions to do separate compilation, you had to rely on extensions to write a subroutine able to accept arrays of varying length, you had to rely on extensions to... you name it) –  AProgrammer Dec 2 '12 at 17:34
4  
Brian Kernighan wrote "Why Pascal is Not My Favorite Programming Language". –  Keith Thompson Dec 2 '12 at 20:56
3  
@KeithThompson, unfortunately, many people quote that essay as an argument against any Pascal extension. It's like quoting an hypothetical article called "Why C is Not My Favorite Programming Language", which would hypothetically talk about the lack of proper classes and inheritance, and use it as an argument against either C++ or Objective C. –  Paulo Madeira Dec 2 '12 at 21:13
2  
@Paulo: Heck, I'd argue that C++ still doesn't have proper classes and inheritance. If an object is a value type, not a reference type, you've broken LSP, the core principle of inheritance and of OOP itself, from the outset. That's why all the other major object-oriented languages (including Simula, which originated the concept, and Smalltalk, which originated the term "object-oriented programming) did not do it that way. –  Mason Wheeler Dec 2 '12 at 21:16
show 4 more comments

... and prior to the Mac (Apple II), most programming was in BASIC. (For all variants of Apple II to the IIgs)

I also recall doing C++ development on System 7 using Metroworks CodeWarrior - this was (of course) post PowerPC.

share|improve this answer
4  
Not really. The old Apples came with BASIC built in, but even by the standards of the day it was regarded mostly as a toy language due to its poor performance and minimal support for sounds and graphics. There were exceptions, of course, but most serious programming on the Apple II systems was done either in Pascal or ASM. –  Mason Wheeler Dec 2 '12 at 16:06
2  
Ah - thanks. My programming experience on the Apple II was all BASIC as it was my first exposure to programming in general. (Hence we stuck with BASIC and that instruction set.). I also recall doing "Logo", but I don't know if anyone did any serious work with it. –  Chad Thompson Dec 2 '12 at 16:11
    
UCSD Pascal was the only "real" language available for the Apple ][ that I remember, but few if any applications used it. If BASIC was too slow for you, you generally went straight to assembly. –  Steven Burnap Dec 2 '12 at 18:10
    
Despite its limitations, I wouldn't doubt that "most programming" those days was done in BASIC. –  dan04 Dec 2 '12 at 18:13
    
@dan04: As far as I can remember assembly was commonly used for programming Apple ][. Switching to monitor mode was one of the first things hackers learnt. –  Giorgio Dec 2 '12 at 19:17
show 1 more comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.