Added default constructors to automatically clear links.

This commit is contained in:
John Wellbelove 2016-10-08 08:58:00 +01:00
parent f4630351a2
commit 6edd27698f

View File

@ -114,6 +114,11 @@ namespace etl
OPTION = OPTION_
};
forward_link_base()
{
clear();
}
void clear()
{
etl_next = nullptr;
@ -329,6 +334,11 @@ namespace etl
OPTION = OPTION_
};
bidirectional_link_base()
{
clear();
}
void clear()
{
etl_previous = nullptr;
@ -662,6 +672,11 @@ namespace etl
OPTION = OPTION_
};
tree_link_base()
{
clear();
}
void clear()
{
etl_parent = nullptr;