Library 3 & Library 4

- resolved bug in library 3 (and in lib4)
- 0 errors in simpletests for library 4
This commit is contained in:
Alessandro Ferro
2021-05-13 18:38:07 +02:00
parent 2b7c59412c
commit 90f20eb405
6 changed files with 108 additions and 85 deletions

View File

@ -419,7 +419,7 @@ void BTPostOrderIterator<Data>::operator++(){
if(stack.Empty()){
curr = nullptr;
}else{
if( curr == &((stack.Top())->LeftChild()) ){
if((stack.Top())->HasLeftChild() && curr == &((stack.Top())->LeftChild()) ){
if( (stack.Top())->HasRightChild() ){
curr = DeepestLeftLeaf(&((stack.Top())->RightChild()));
}else{