


Developer Tries Resurrecting 47-Year-Old 'Apple Pascal' (and its p-System) in Rust (markbessey.blog) 19
Long-time Slashdot reader mbessey (a Mac/iOS developer) writes:
As we're coming up on the 50th anniversary of the first release of UCSD Pascal, I thought it would be interesting to poke around in it a bit, and work on some tools to bring this "portable operating system" back to life on modern hardware, in a modern language (Rust).
Wikipedia describes UCSD Pascal as "a version that ran on a custom operating system that could be ported to different platforms. A key platform was the Apple II, where it saw widespread use as Apple Pascal. This led to Pascal becoming the primary high-level language used for development in the Apple Lisa, and later, the Macintosh. Parts of the original Macintosh operating system were hand-translated into Motorola 68000 assembly language from the Pascal source code."
mbessey is chronicling their new project in a series of blog posts which begins here: The p-System was not the first portable byte-code interpreter and compiler system — that idea goes very far back, at least to the origins of the Pascal language itself. But it was arguably one of the most-successful early versions of the idea and served as an inspiration for future portable software systems (including Java's bytecode, and Infocom's Z-machine).
And they've already gotten UCSD Pascal running in an emulator and built some tools (in Rust) to transfer files to disk images. Now they're working towards writing a p-machine emulator in Rust, which they can they port to "something other than the Mac. Ideally, something small â" like an Arduino or Raspberry Pi Pico."
Wikipedia describes UCSD Pascal as "a version that ran on a custom operating system that could be ported to different platforms. A key platform was the Apple II, where it saw widespread use as Apple Pascal. This led to Pascal becoming the primary high-level language used for development in the Apple Lisa, and later, the Macintosh. Parts of the original Macintosh operating system were hand-translated into Motorola 68000 assembly language from the Pascal source code."
mbessey is chronicling their new project in a series of blog posts which begins here: The p-System was not the first portable byte-code interpreter and compiler system — that idea goes very far back, at least to the origins of the Pascal language itself. But it was arguably one of the most-successful early versions of the idea and served as an inspiration for future portable software systems (including Java's bytecode, and Infocom's Z-machine).
And they've already gotten UCSD Pascal running in an emulator and built some tools (in Rust) to transfer files to disk images. Now they're working towards writing a p-machine emulator in Rust, which they can they port to "something other than the Mac. Ideally, something small â" like an Arduino or Raspberry Pi Pico."
Re: (Score:1)
mbessey is chronicling their new project
His name is literally Mark. Why do the editors on this piece of shit news site keep pretending that the people they write about exist in some form of agender state despite obvious proof to the contrary?
The use of "they" when the gender is unknown goes back a very long time. For example,
"I saw somebody."
"What did they look like?"
Is perfectly normal English. Why is it so troubling for you to do so just because you think you know the gender?
Re: (Score:1)
His (Mark's) sex is known. Proper English dictates that "his" is appropriate while "their" is not.
Re: (Score:1)
I infer the argument is that Slashdot editors are too fucking stupid to know that Mark is a man's name. It tracks.
Re: (Score:2)
The Oxford English Dictionary traces singular they back to 1375, where it appears in the medieval romance William and the Werewolf.
See https://www.oed.com/discover/a... [oed.com]
Re: (Score:2)
How’s the Gulf Of Mexico doing? The pope also has a new pronoun.
If anyone needs it (Score:2)
I have a complete set of Inside Macintosh still lying around somewhere.
Wizardry series in Rust? (Score:3)
If the p-system can be ported to Rust, I wonder if games that use it, like the OG Wizardry series, can be ported as well.
Re:Wizardry series in Rust? (Score:5, Interesting)
Yes, with a caveat. Apple Pascal has some native 6502 routines as extensions to the standard UCSD Pascal. These will have to be translated, ideally to p-Code, and wired into something in the emulator. But I'd *like to* do that, once I have things up and running.
awesome (Score:1)
Re: (Score:2)
Why in the world would you want a new interpreter for the Apple II? The one that exists is fine. And yes - people *have* done this before, mostly rather a long time ago. Building another version of the same thing isn't a bad thing, especially if it comes along with better documentation of the internals, in a way that's accessible to a modern audience.
Unsurprisingly, the 25-year-old project you refer to doesn't build on my system. And neither does the version Peter Miller updated way back in 2010. It's proba
Like when Linux reimplemented UNIX (Score:2)
Why in the world would you want a new interpreter for the Apple II? The one that exists is fine.
Why in the world would Linus Torvalds want a new kernel to run GNU on a PC? The commercial UNIX kernels that existed were fine.
Re: (Score:1)
It is not for Apple II, it is a general purpose "reimplementation", at least that is what I understand. ... not really the "most portable" format to get it quickly running on a Pi or something.
To adapt the byte code to modern CPUs you basically only need to switch to 32bit or bigger pointers, and think about branch and jump instructions.
Having a base implementation in a modern language might be a good thing anyway.
The p-Code implementations I saw so far were all either 6502 or Z80
Re: (Score:2)
Yeah, it would have to be an ARM-based Arduino, to use the Rust version. But there are several of those now, and they're not even necessarily more-expensive than the AVR versions.
Is Pascal still a thing? (Score:2)
Delphi programming language (Score:2)
It seems like BASIC outlived Pascal. I haven't seen it in use in forever.
"Delphi is a general-purpose programming language and a software product that uses the Delphi dialect of the Object Pascal programming language and provides an integrated development environment (IDE) for rapid application development of desktop, mobile, web, and console software,[3] currently developed and maintained by Embarcadero Technologies.
...
Delphi's compilers generate native code for Microsoft Windows, macOS, iOS, Android and Linux (x64).[4][5][6]
Delphi was originally developed by Borland as a ra