Microsoft KB Archive/65569

= BC.EXE May Hang Using Single Quotation Marks in String CONST =

Article ID: 65569

Article Last Modified on 11/21/2006



This article was previously published under Q65569



SYMPTOMS
If you use an editor other than QB.EXE to write a program and BC.EXE hangs at compile time, one possible cause is the use of single quotation marks to delimit a string literal when declaring a string CONST. Using single quotation marks to delimit a string constant rather than double quotation marks is incorrect syntax and is flagged by QB.EXE, but may cause the BC.EXE compiler to hang. In QuickBasic version 3.00, QB.EXE will also hang as a result of using single quotation marks.

This problem occurs in Microsoft QuickBasic versions 3.00, 4.00, 4.00b, and 4.50, and in Microsoft Basic Compiler versions 6.00 and 6.00b (buglist6.00, buglist6.00b) for MS-DOS and OS/2. This problem was corrected in Microsoft Basic Professional Development System (PDS) version 7.00 (fixlist7.00) for MS-DOS and OS/2.



MORE INFORMATION
When the following one-line program is written with an editor other than QB.EXE and compiled using BC.EXE, the BC.EXE compiler will hang. (In QuickBasic 3.00, QB.EXE will hang): CONST A$ = 'Hello World' The compiler may generate the error &quot;R6000: internal stack overflow&quot; before it hangs, or it may go into an infinite loop, generating &quot;R6000: Internal stack overflow&quot; errors.

To work around this problem, use the correct syntax, as follows: CONST A$ = &quot;Hello World&quot; Note: The CONST statement was first introduced in QuickBasic 3.00.

Additional query words: QuickBas buglist3.00 buglist4.00 buglist4.00b buglist4.50

Keywords: KB65569

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.