ホーム › System.Rpc › I_RpcFree
I_RpcFree
関数I_RpcAllocateで割り当てたメモリを解放する内部関数。
シグネチャ
// RPCRT4.dll
#include <windows.h>
void I_RpcFree(
void* Object
);パラメーター
| 名前 | 型 | 方向 |
|---|---|---|
| Object | void* | inout |
戻り値の型: void
各言語での呼び出し定義
// RPCRT4.dll
#include <windows.h>
void I_RpcFree(
void* Object
);[DllImport("RPCRT4.dll", ExactSpelling = true)]
static extern void I_RpcFree(
IntPtr Object // void* in/out
);<DllImport("RPCRT4.dll", ExactSpelling:=True)>
Public Shared Sub I_RpcFree(
[Object] As IntPtr ' void* in/out
)
End Sub' Object : void* in/out
Declare PtrSafe Sub I_RpcFree Lib "rpcrt4" ( _
ByVal Object As LongPtr)
' VBA7前提(PtrSafe)。32bit Office では LongPtr→Long。Integer=16bit / Long=32bit / LongLong=64bit。import ctypes
from ctypes import wintypes
I_RpcFree = ctypes.windll.rpcrt4.I_RpcFree
I_RpcFree.restype = None
I_RpcFree.argtypes = [
ctypes.POINTER(None), # Object : void* in/out
]require 'fiddle'
require 'fiddle/import'
lib = Fiddle.dlopen('RPCRT4.dll')
I_RpcFree = Fiddle::Function.new(
lib['I_RpcFree'],
[
Fiddle::TYPE_VOIDP, # Object : void* in/out
],
Fiddle::TYPE_VOID)#[link(name = "rpcrt4")]
extern "system" {
fn I_RpcFree(
Object: *mut () // void* in/out
);
}
// crates: windows-sys provides ready-made bindings for this API.$sig = @"
[DllImport("RPCRT4.dll")]
public static extern void I_RpcFree(IntPtr Object);
"@
$api = Add-Type -MemberDefinition $sig -Name 'RPCRT4_I_RpcFree' -Namespace Win32 -PassThru
# $api::I_RpcFree(Object)#uselib "RPCRT4.dll"
#func global I_RpcFree "I_RpcFree" sptr
; I_RpcFree Object
; Object : void* in/out -> "sptr"#uselib "RPCRT4.dll"
#func global I_RpcFree "I_RpcFree" sptr
; I_RpcFree Object
; Object : void* in/out -> "sptr"; void I_RpcFree(void* Object)
#uselib "RPCRT4.dll"
#func global I_RpcFree "I_RpcFree" intptr
; I_RpcFree Object
; Object : void* in/out -> "intptr"import (
"golang.org/x/sys/windows"
"unsafe"
)
var (
rpcrt4 = windows.NewLazySystemDLL("RPCRT4.dll")
procI_RpcFree = rpcrt4.NewProc("I_RpcFree")
)
// Object (void* in/out)
r1, _, err := procI_RpcFree.Call(
uintptr(Object),
)
_ = err // syscall.Errno (valid when the call sets last-error)
_ = r1 // voidprocedure I_RpcFree(
Object: Pointer // void* in/out
); stdcall;
external 'RPCRT4.dll' name 'I_RpcFree';result := DllCall("RPCRT4\I_RpcFree"
, "Ptr", Object ; void* in/out
, "Int") ; return: void●I_RpcFree(Object) = DLL("RPCRT4.dll", "int I_RpcFree(void*)")
# 呼び出し: I_RpcFree(Object)
# Object : void* in/out -> "void*"
# なでしこ1は32bit・ANSI(Shift_JIS)。文字列=char*(ANSI)、ポインタ/ハンドル=void*(4byte)。