This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

ARM: deleting a task and stack unwinding

Hello!

I have a question about os_tsk_delete() function from keil. I am wondering what happens to task's stack when you call the delete function. Does it unwinds like normal functions when they return?

A little bit of info why I am asking. I was wondering what happens if I have a task, that has a class inside it like so:

class A
{
    ~A();
}
__task void taskFunction(void *argv)
{
    A a;
    while(true);
}

Now lets say I delete the task by using os_tsk_delete() function. Does the destructor of class A get called?

Thanks in advance for any useful information!