Projects, Technology 2016-08-31

Progress on OspreyForth, Aug. 30

A project update on OspreyForth.

OspreyForth is coming along, although I haven’t tried to compile everything yet. The Objective-C Runtime has something between 30 and 40 API calls, and I’ve been going at them a bit at a time.

The interesting thing about how pForth (the Forth interpreter I’m using for this new version of OspreyForth) works is that everything is handled through an intptr, which is an integer data type the same size as a pointer. The intptr is typdef’d as a cell_t type, which is what pForth passes around for everything. As a result, receiving and passing data types is easier than last time around when I was casting pointers all over the place.

That said, I’ve never really used intptr before, so I hope the Objective-C runtime doesn’t choke on them. I’ve been doing some casting in certain areas just in case, but we’ll see what happens.

Once all the APIs are hooked up, I’ll try a compile and cross my fingers! (shudder)

About the author

Erik Hentell: I started out in theater before moving to graphic design. I eventually moved into web design while trying to expand my knowledge on software development. I currently work for a media company helping with their digital assets such as source code archives and ebooks.