double linked list -- deallocate all list

double linked list -- deallocate all list

hi everyone,In my program I create a double linked list.I would like to know if it is possible to deallocate all the list in a simple way.I mean, Can I apply a sort of code like:

DEALLOCATE (MY_LIST())
or, as I suppose, I have to move across the entire list and ramove the node one by one?In the second case how can I do?cheers

2 posts / novo 0
Último post
Para obter mais informações sobre otimizações de compiladores, consulte Aviso sobre otimizações.

I am going to assume you are coding in Fortran, as the syntax you show is closer to Fortran than C/C++.

In order to have a linked list you would have to use POINTER components of a derived type. There is no way to deallocate the whole list in one statement.

If you need further help on Fortran, please ask in one of our Fortran-specific forums. We have one for Windows and another for Linux/Mac.

Steve - Intel Developer Support

Deixar um comentário

Faça login para adicionar um comentário. Não é membro? Inscreva-se hoje mesmo!