diff options
author | Arnaud Versini <arnaud.versini@gmail.com> | 2015-12-19 15:18:01 +0100 |
---|---|---|
committer | Michael Stahl <mstahl@redhat.com> | 2016-01-07 12:18:40 +0000 |
commit | 5e0d36adc3f7f245edfc79230d0871017ba15d5d (patch) | |
tree | b26f52373a20adb65041a79da23803503abad030 /basic/source/comp/exprnode.cxx | |
parent | a8b10c2841bf38e0f4393594de9b61d9bd3cd842 (diff) |
BASIC : use std::vector instead of SbArray for Modules.
Change-Id: I9594efb13b3dccc637ccd61eea4b42255c2a775c
Reviewed-on: https://gerrit.libreoffice.org/20817
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Michael Stahl <mstahl@redhat.com>
Diffstat (limited to 'basic/source/comp/exprnode.cxx')
-rw-r--r-- | basic/source/comp/exprnode.cxx | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/basic/source/comp/exprnode.cxx b/basic/source/comp/exprnode.cxx index 9d77f6dba071..19272dc3da6a 100644 --- a/basic/source/comp/exprnode.cxx +++ b/basic/source/comp/exprnode.cxx @@ -19,6 +19,7 @@ #include <math.h> +#include <algorithm> #include <rtl/math.hxx> #include "codegen.hxx" @@ -191,9 +192,7 @@ short SbiExprNode::GetDepth() if( IsOperand() ) return 0; else { - short d1 = pLeft->GetDepth(); - short d2 = pRight->GetDepth(); - return( (d1 < d2 ) ? d2 : d1 ) + 1; + return std::max(pLeft->GetDepth(), pRight->GetDepth()) + 1; } } |