1 ' This file is part of the LibreOffice project.
3 ' This Source Code Form is subject to the terms of the Mozilla Public
4 ' License, v. 2.0. If a copy of the MPL was not distributed with this
5 ' file, You can obtain one at http://mozilla.org/MPL/2.0/.
10 Function doUnitTest
As String
11 ' Trying to create too long string should generate proper BASIC overflow error.
12 ' Longest possible string is 2147483638 wchar_t (2G - 10).
13 ' This tries to create string with 2G wchar_t. If it does not overflow, test fails.
14 ' If overflow is not safe, it segfaults.
15 On Error GoTo errorHandler
16 Dim s
As String, i
As Integer