https://bugs.documentfoundation.org/show_bug.cgi?id=150491
Bug ID: 150491
Summary: Infinite recursion in a VBA macro that works without
errors in Excel
Product: LibreOffice
Version: unspecified
Hardware: All
OS: All
Status: UNCONFIRMED
Severity: normal
Priority: medium
Component: BASIC
Assignee: [email protected]
Reporter: [email protected]
Created attachment 181876
--> https://bugs.documentfoundation.org/attachment.cgi?id=181876&action=edit
An XLSM with a VBA macro showing infinite recursion in LibreOffice Basic
Running 'main' macro from the attachment produces this error:
> BASIC runtime error.
> '28'
> Not enough stack memory.
It runs OK in Excel, showing a message box with "1".
The macro code there is this:
Option VBASupport 1
Function NotRecursive()
Set NotRecursive = New Collection
NotRecursive.Add "Foo"
End Function
Sub main()
Dim c
Set c = NotRecursive
MsgBox c.Count
End Sub
The infinite recursion happens on 'NotRecursive.Add "Foo"', where LibreOffice
Basic tries to call the function again.
Possibly this should only be fixed in VBASupport mode.
--
You are receiving this mail because:
You are the assignee for the bug.