fdo#86169 fix completion of function name crash

function names with dot or underscore were not completed
correctly, leading to incorrect results or even crashes

Change-Id: Iacb6af29c609ab39746185c71d4443537bf46b5e
Reviewed-on: https://gerrit.libreoffice.org/12380
Reviewed-by: Eike Rathke <erack@redhat.com>
Tested-by: Eike Rathke <erack@redhat.com>
(cherry picked from commit 5456abc4d734583664a55c01a0e750e3051b03c9)
Signed-off-by: Eike Rathke <erack@redhat.com>
(cherry picked from commit d4aa91aa4cf7a01915cb9a2b1e4d52e20bf7454b)
Reviewed-on: https://gerrit.libreoffice.org/13155
Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>