private static boolean resolveThunk(Program program, Address entry, AddressSetView body,
			TaskMonitor monitor) {

		Address thunkedAddr = CreateThunkFunctionCmd.getThunkedAddr(program, entry);
		if (thunkedAddr == null || thunkedAddr.equals(entry)) {
			return false;
		}

		// don't know the body of the thunk.
		CreateThunkFunctionCmd cmd = new CreateThunkFunctionCmd(entry, body, thunkedAddr);
		if (cmd.applyTo(program, monitor)) {
			return true;
		}
		return false;
	}
Check and create a thunk function at entry.
Called due to a function body change, or a reference having been created
so there is no body

@param program function is in
@param entry entry point of the function
@param monitor to allow canceling

@return true if a thunk was created.
Ghidra/Features/Base/src/main/java/ghidra/app/cmd/function/CreateFunctionCmd.java