How to unset a function definition just like we unset a variable?

后端 未结 5 887
小鲜肉
小鲜肉 2020-12-10 11:15

I want to define a function and unset it after its use just like we do with variables.

$a = \'something\';
unset($a);
echo $a; // outputs nothing
         


        
5条回答
  •  失恋的感觉
    2020-12-10 11:27

    runkit_function_removeRemove a function definition http://php.net/manual/en/function.runkit-function-remove.php

提交回复
热议问题