refactor assignment out of complex expression

Change-Id: I55ecededc829a6cd1a7bb1aeb2bcae65406e0b2b
Reviewed-on: https://gerrit.libreoffice.org/12993
Reviewed-by: Björn Michaelsen <bjoern.michaelsen@canonical.com>
Tested-by: Björn Michaelsen <bjoern.michaelsen@canonical.com>