In the Star Trek franchise, a number of characters "reprogram a computer" or "write a holodeck program" or do similar sorts of programming. Has is ever been identified what sort of languages are in use in this universe?
No, seriously, they still use C++. Heck, they're even still doing their own memory management!
In Star Trek: Discovery 1x03 "Context is for Kings", Stamets asks Burnham to "reconcile these two pieces of code". When she later shows the location where the error is, it's clearly C++, or something remarkably similar to it.
Here are the last few lines of the code:
LPVOID _stdcall VirtualAlloc(LPVOID ipAddress, SIZE_T dwSize, flAllocationType, DWORD flProtect); HANDLE _stdcall CreateMutexW(LPSECURITY_ATTRIBUTES ipMutexAttributes, BOOL bInitialOwner; LPCWSTR ipName); UINT _stcall SetErrorMode(UINT uMode); BOOL _stdcall FreeLibrary(HMODULE hLibModule);
And yeah, you could probably argue that this C++ is placeholder for just "really complex-looking code", but given that Burnham debugging this specific piece of code is a plot point in the episode, I'm going to count it.
Thanks to Jules in the comments for finding the source of this code!
.. interestingly, that code appears to be the real-world source code for the standard Windows system component,
kernel32.dll. Or a very near replica of it. Possibly an automated reverse engineering of it, given the poor choice of variable names.
The function that's shown in full (rather than just as a header) is
GetCurrentProcess-- the windows documentation for that shows that it is part of kernel32.dll. Wikipedia comments that kernel32.dll mostly just delegates functionality to ntdll.dll, which you can see is exactly what the code shown is doing: it loads a reference to ntdll.dll, finds a pointer to a function from it, then calls it.
So apparently, they're still using Microsoft Windows in the 23rd Century and bugs are preventing Starfleet's science division from getting any work done! So much for Gene Roddenbery's dream of a utopic future!
In Discovery Season 2, Episode 8 (If Memory Serves), they talk about
"...multiple SQL Injections".
It's 2250 and people still don't clean user input.