Official C++ support for Playdate SDK

,

TL;DR - Is there official C++ support for Playdate being worked on? If not, could there be?

Hey all! Just started developing for the Playdate and I
am loving the Dev experience on Windows. I was wondering if an official C++ SDK is in the works? Or if there is an official stance on whether one will be released or not? I have found the guide on these forums for helping to get projects to compile with C++ and I have seen some others post about modifications to the SDK they made to allow C++ code to compile and link. However, it would be awesome if there was an official C++ version of the SDK or at the very least some official C++ glue code provided in the SDK along with a guide on how to compile C++ code for the Playdate. It is very clearly possible to do, but it seems to be very hacky at the minute.

I believe that having official support for C++ could help developers with making games. There is clearly an appetite for it considering that there are forum posts about it and university papers around the subject. And if people are able to get it working with a little hacking, it is probably worth having official support for it, if possible. I know that if C++ was officially supported, I would jump from C to it in a heartbeat. There are so many great features in C++ that makes code much more expressive and involves much less boilerplate code.

We don't have official support, but you could take a look at this thread:

Oh, you did mention that you found that guide already. My mistake.

Yes so there has been some work to hack it in. However, I mainly wanted to know if there is a roadmap for official support? Or if there is no intention to support it? Does the Dev team care if future SDK updates break the current ways of getting C++ to work or are they intended to be defacto official and the Dev team will endeavour to ensure that they always work?

Official support is on the list, but a low priority.

2 Likes

@willco There's an easy, 2- or 3- line change that could be implemented that makes C++ very easy to set up. It can be implemented directly in the linker script and main file that ship with the SDK. It shouldn't take more than a quick glance from an engineer to verify that it works and is okay to include in the next SDK. It would make sharing C++ code between playdate developers much easier, as then we don't need to implement those changes in the SDK ourselves. I would really appreciate it if someone from Panic were to take a look at it. :slight_smile:

Edit: okay it's more like 30 lines but it's just in 2 places so it's not so bad.