/* This function will detach a static object from object system, and the memory of static object is not freed. */
void rt_object_detach(rt_object_t object)
/* This function will detach a static object from object system, and the memory of static object is not freed. */
void rt_object_detach(rt_object_t object)
{
    register rt_base_t temp;
    RT_ASSERT(object != RT_NULL);
    RT_OBJECT_HOOK_CALL(rt_object_detach_hook, (object));
    object->type = 0;
    temp = rt_hw_interrupt_disable();
    rt_list_remove(&(object->list));
    rt_hw_interrupt_enable(temp);
}