"Usage of GetFuncPtr()"

unsafe {
	delegate* unmanaged<char*> getHelloStrFuncPtr;
	NativeMethods.GetFuncPtr(&getHelloStrFuncPtr);
	Console.WriteLine(new String(getHelloStrFuncPtr())); // Writes "Hello" to the console
}


Code snippet taken from "Complete C# Quick Reference - C# 9".