LO 80731 - Incorrect syntax does compile, MID without end bracket

Kaganski Mike mikekaganski at hotmail.com
Wed Jun 28 11:08:07 UTC 2017


On 6/28/2017 2:03 PM, Stephan Bergmann wrote:
> On 06/28/2017 12:12 PM, Pierre Lepage wrote:
>> The solution brings a lot of hassle for customers of the LibreOffice 
>> suite whose work relies on the performance of StarBasic macros written 
>> by third parties. Macros containing code in error by the absence of a 
>> closing parenthesis suddenly cease to function. For this reason, the 
>> patch has not been released. Here I want to explore a transitional 
>> solution by getting your feedback first. This is to include in 
>> StarBasic options dialog accessible to the client a "StarBasic Pragma 
>> Strict" option (checkbox) by which the client consciously activates 
>> the solution (the patch that has not been published!). This check box 
>> would be available for a few years with a warning to prompt 
>> programmers and customers to require their programmer to correct their 
>> default code on the closing parenthesis.
> 
> Another option might be to have some form of such a pragma in individual 
> BASIC source files, instead of as an IDE option.  (And have the pragma 
> enabled in the "REM ***** BASIC ****** Sub Main ... End Sub" boilerplate 
> that is automatically present in a fresh source file.)  That way, users 
> could enable it for their own, new code, while (implicitly) keeping it 
> off for non-conforming old, 3rd-party code.

I'd suggest also a special handling of "Compile" IDE command. It should 
always use strict parsing method. As it is a developer's tool, used when 
something is created anew, it would help all developers catch the 
problem early even when they don't know the strict option (wherever it be).

-- 
Best regards,
Mike Kaganski


More information about the LibreOffice mailing list