[Libreoffice-bugs] [Bug 101631] VBA function parameter is passed by reference by default

bugzilla-daemon at bugs.documentfoundation.org bugzilla-daemon at bugs.documentfoundation.org
Tue Sep 14 09:46:20 UTC 2021


https://bugs.documentfoundation.org/show_bug.cgi?id=101631

--- Comment #9 from Eike Rathke <erack at redhat.com> ---
Normally (...) for user defined functions that are invoked as spreadsheet
functions, yes.

Now it gets complicated: for whatever reason (I don't know the history behind
that specific VBA implementation) if there is
Option VBASupport 1
which here is the case then a XCellRange object is passed for cell references.
That indeed allows BASIC to modify the cell. It should not and can result in
undesired side effects, like here even Err:522 circular references being
detected because the cell value modified triggers another recalc that runs into
a currently being calculated cell.

Changing stableford() to not modify its score argument gets rid of all side
effects.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/libreoffice-bugs/attachments/20210914/debaed30/attachment.htm>


More information about the Libreoffice-bugs mailing list