php4에서 function내에 static 지시자 사용가능함을 재확인하여 r4260 rollback

git-svn-id: http://xe-core.googlecode.com/svn/sandbox@4262 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
zero 2008-06-10 00:29:20 +00:00
parent ef0c5cb063
commit 7599000680

View file

@ -50,11 +50,12 @@
/** /**
* @brief 유일한 Context 객체를 반환 (Singleton) * @brief 유일한 Context 객체를 반환 (Singleton)
* *
* Context는 어디서든 객체 선언없이 사용하기 위해서 GLOBALS 변수에 저장후 재사용 (php4 호환 때문에) * Context는 어디서든 객체 선언없이 사용하기 위해서 GLOBALS 변수에 저장후 재사용
**/ **/
function &getInstance() { function &getInstance() {
if(!$GLOBALS['__ContextInstance__']) $GLOBALS['__ContextInstance__'] = new Context(); static $theInstance;
return $GLOBALS['__ContextInstance__']; if(!isset($theInstance)) $theInstance = new Context();
return $theInstance;
} }
/** /**