このページを編集する際は、編集に関する方針に従ってください。

概要

__GNUC__ が定義されている場合(postgresql-8.1.4/src/include/utils/palloc.h)

上記以外(postgresql-8.1.4/src/backend/utils/mmgr/mcxt.c

引数

実装

__GNUC__ が定義されている場合(postgresql-8.1.4/src/include/utils/palloc.h

static __inline__ MemoryContext
MemoryContextSwitchTo(MemoryContext context)
{
	MemoryContext old = CurrentMemoryContext;
	CurrentMemoryContext = context;
	return old;
}

上記以外(postgresql-8.1.4/src/backend/utils/mmgr/mcxt.c

MemoryContext MemoryContextSwitchTo(MemoryContext context)

{

	MemoryContext old;
	AssertArg(MemoryContextIsValid(context));
	old = CurrentMemoryContext;
	CurrentMemoryContext = context;
	return old;

}

呼出元

備考

/*
* MemoryContextSwitchTo can't be a macro in standard C compilers.
* But we can make it an inline function when using GCC.
*/

履歴

コメント



*1 99333685+99333685
*2 99333685+99333685
*3 99333685+99333685
*4 99333685+99333685
*5 99333685+99333685
*6 99333685+99333685

トップ   新規 一覧 単語検索 最終更新   ヘルプ   最終更新のRSS