Beef icon indicating copy to clipboard operation
Beef copied to clipboard

[Bug] Autocomplete tooltip doesn't always show declaration or return values when otherwise would be expected

Open marsej opened this issue 4 years ago • 1 comments

When hovering mouse over GetSizedHelper below in Process.bf ...

public static Result GetProcesses(List<Process> processes) { let result = Platform.GetSizedHelper<Platform.BfpProcess*>(scope (outPtr, outSize, outResult) =>

... the autocomplete tooltip shows: System.Result<void, System.Platform.Result>.ReturnValueDiscarded();

What was expected instead:

Result<Span<T>, Platform.Result> GetSizedHelper<T>(delegate void (T* outPtr, int32* outSize, Result* outResult) func)

marsej avatar Apr 02 '21 11:04 marsej

In 0.43.1 the result has improved but there still are cases where the return value is not shown:

BeefLibs\corlib\src\Platform.bf:
		public static extern int32 BfpProcess_GetProcessId(BfpProcess* process);

BeefLibs\corlib\src\Diagnostics\Process.bf
		public int32 Id
		{
			get
			{
				return Platform.BfpProcess_GetProcessId(mProcess);
			}
		}


If I hover mouse over Platform.BfpProcess_GetProcessId it says "System.Platform.BfpProcess_GetProcessId(System.Platform.BfpProcess* process)"

expected result:

"int32 System.Platform.BfpProcess_GetProcessId(System.Platform.BfpProcess* process)"

(more like C# in VS)

marsej avatar Dec 09 '21 02:12 marsej