Add support for clangd in the python tools (#120)

* initial clangd support through python

* update install instructions

* invert configure.py behavior

* fix oopsie

* fix few issues from clangd

* fix related build issues
This commit is contained in:
Yanis
2026-07-21 19:37:21 +02:00
committed by GitHub
parent 04d20febb1
commit bc04021bc0
15 changed files with 322 additions and 51 deletions
+3 -1
View File
@@ -34,6 +34,7 @@ bool ActorUnkSWOB::vfunc_18(unk32 param1) {
this->SetState(ActorUnkSWOBState_0);
}
#pragma unused(param1)
return true;
}
@@ -70,7 +71,7 @@ void ActorUnkSWOB::func_ov000_0209aa30(void) {
case 1:
data_ov000_020b5214.func_ov000_0206db44(0xA3);
break;
case 3:
case 3: {
data_ov000_020b5214.func_ov000_0206db44(0xA3);
s16 unk_78 = this->mUnk_5C.mUnk_1A[1];
@@ -78,6 +79,7 @@ void ActorUnkSWOB::func_ov000_0209aa30(void) {
data_027e0cd8->func_ov000_02081d7c((s16) (unk_78 - 1), this->mUnk_5C.mUnk_18[1], true);
}
break;
}
case 2: {
VecFx32 temp;
VecFx32 vec2;
+5 -5
View File
@@ -75,8 +75,8 @@ void UnkStruct_027e0cd8::func_ov001_020b7830(const EntranceInfo *param1) {
pUnk1 = data_027e09a0->func_ov000_020702a8(param1->sceneIndex);
wchar_t sp80[16];
sp80[0] = L'\0';
sp80[sizeof(sp80) / 2 - 1] = L'\0';
sp80[0] = L'\0';
sp80[ARRAY_LEN(sp80) - 1] = L'\0';
snprintf((char *) sp80, sizeof(sp80), "Map/%s/course.bin", pEntry->name);
UnkStruct2 sp70((char *) sp80, 0x01);
@@ -123,8 +123,8 @@ void UnkStruct_027e0cd8::func_ov001_020b7830(const EntranceInfo *param1) {
if (pEntry->unk_21 != -1) {
wchar_t sp30[16];
sp30[0] = L'\0';
sp30[sizeof(sp30) / 2 - 1] = L'\0';
sp30[0] = L'\0';
sp30[ARRAY_LEN(sp30) - 1] = L'\0';
snprintf((char *) sp30, sizeof(sp30), "Map/%s/course.bin", data_027e09a0->GetCourseEntry(pEntry->unk_21)->name);
@@ -254,7 +254,7 @@ void UnkStruct_027e0cd8::func_ov001_020b7c08(const EntranceInfo *param1, const U
this->func_ov001_020b7e50();
if (sceneChange.roomIndex != ROOM_INDEX_NONE) {
if (this->mUnk_30 == sceneChange.sceneIndex && DSProt_DetectNotEmulator(func_ov084_0216122c) == 0) {
if (this->mUnk_30 == sceneChange.sceneIndex && DSProt_DetectNotEmulator((void *) func_ov084_0216122c) == 0) {
func_ov084_021612ac();
}
+2 -2
View File
@@ -134,7 +134,7 @@ void Game::Run() {
{
int enabled = OS_DisableInterrupts_Irq();
this->mUnk_1C.func_02013e18(func_020132dc, 0);
this->mUnk_1C.func_02013e18((void *) func_020132dc, 0);
REG_GFX_FIFO_SWAP_BUFFERS = 3;
OS_RestoreInterrupts(enabled);
}
@@ -143,7 +143,7 @@ void Game::Run() {
if (this->mUnk_18 != NULL) {
while (this->mUnk_18() != 0) {
while (this->mUnk_1C.func_02013e18(func_02013354, 0) == 0) {
while (this->mUnk_1C.func_02013e18((void *) func_02013354, 0) == 0) {
}
func_020132c8();
+2 -1
View File
@@ -85,7 +85,7 @@ void SysFault::func_020127f0(unk32 param1) {
switch (param1) {
case 0:
case 1:
case 1: {
data_02049b18.mButtons.func_02013b24(data_02049b18.mButtons.func_02013bbc());
u16 expected = data_0203e0c4[this->mUnk_04];
@@ -108,6 +108,7 @@ void SysFault::func_020127f0(unk32 param1) {
doDraw = false;
break;
}
case 2:
case 3:
default:
+1 -2
View File
@@ -1,5 +1,4 @@
#include "System/SysNew.hpp"
#include "global.h"
extern "C" {
void *func_02001654(void *);
@@ -68,7 +67,7 @@ void *func_02011f30(s32 length) {
return func_02011f10(length);
}
void *operator new(unsigned long length, u32 id, u32 idLength) {
void *operator new(size_t length, u32 id, u32 idLength) {
void *pvVar1;
UnkStruct_02011e10_Sub1 *pUVar5;