Decompilation is broken after jumping to imported function

For ARM64 had this since v8 and still in v9.5 behaves same

Load any .so and decompile any function that has other function call with arguments and function called is imported from other .so

property_get(a1: "persist.vendor.camera.ov48c.ShortGain", a2: nptr, a3: "2");

then double click property_get which is imported function it will jump to function that would read

// attributes: thunk
__int64 __fastcall property_get()
{
return property_get();
}

then go back to previous function press F5 to refresh and de compilation breaks it becomes

property_get(a1: "persist.vendor.camera.ov48c.ShortGain", a2: nptr, a3: "2");
becomes
property_get();

all values are gone no way to reverse back.

Only fix is to open prototype of function before double clicking property_get and it will show

__int64 __fastcall property_get(_QWORD, _QWORD, _QWORD);

then press OK and it will run some update so now after double clicking property_get it shows as

// attributes: thunk
__int64 __fastcall property_get(__int64 a1, __int64 a2, __int64 a3)
{
return property_get(a1, a2, a3);
}

and going back and refreshing does not break the decompilation anymore.

I feel like that step with opening prototype and pressing OK should be automated when you double click its just inconvenient sometimes i double click by mistake and getting this.

Can upload example .so if you want to reproduce.

this happens because the PLT stub for the external call goes to an unknown location so IDA has no information about its arguments and removes them from the prototype.

Getting back the guessed call arguments is simple: reset the wrong no-arg prototype using Y, Del, Enter.