Bug 050322401: const expressions

List of known bugs
Post Reply
Author
Message
nikola
mikroElektronika team
Posts: 137
Joined: 03 Aug 2004 12:44
Contact:

Bug 050322401: const expressions

#1 Post by nikola » 24 Mar 2005 16:40

Bug ID: #050322401
Submitted by: LGR

Severity: Annoyance
Status: In progress

Description:
Compiler expects a literal (and literal only) where constant expression should be expected.

Example:

Code: Select all

const SIZE = 32;
var stack : array[SIZE] of byte;
// returns an error: identifier SIZE not declared
Workaround:
Use literals instead of constants, e.g.

Code: Select all

var stack : array[32] of byte;
-

Post Reply

Return to “mikroPascal for dsPIC30/33 and PIC24 Bug List”