Microsoft KB Archive/102367: Difference between revisions

From BetaArchive Wiki
(importing KB archive)
 
m (Text replacement - ">" to ">")
 
(One intermediate revision by the same user not shown)
Line 86: Line 86:
  */  
  */  


#include <iostream.h>
#include <iostream.h>
typedef enum
typedef enum
{
{
Line 109: Line 109:
   port = new TEST;
   port = new TEST;
   // NOTE: Must refer to linkstate for CXX0033 error to occur.
   // NOTE: Must refer to linkstate for CXX0033 error to occur.
   port-&gt;linkstate;
   port->linkstate;
   delete port;
   delete port;
}
}

Latest revision as of 17:42, 20 July 2020

Knowledge Base


Article ID: 102367

Article Last Modified on 8/16/2005



APPLIES TO

  • Microsoft CodeView 4.0
  • Microsoft CodeView 4.01
  • Microsoft CodeView 4.01
  • Microsoft CodeView 4.1
  • Microsoft CodeView 4.0
  • Microsoft CodeView 4.01
  • Microsoft CodeView 4.1
  • Microsoft Visual Workbench for Windows



This article was previously published under Q102367

SYMPTOMS

An attempt to display a variable in the Locals, QuickWatch, or Watch windows fails and CodeView or Visual Workbench displays the following message:

CXX0030 : Error : expression cannot be evaluated

CAUSE

The application uses a type-defined enumerated bitfield in a class type and the user attempts to display the value of a variable of that type. The CXX0030 error may not occur if you do not attempt to display it.

STATUS

Microsoft has confirmed this to be a problem in CodeView versions 4.0x and 4.1 for MS-DOS and Windows and in Visual Workbench version 1.0 for Windows.

This is not a problem in CodeView version 4.25 for Win32s.

MORE INFORMATION

The following code example demonstrates this problem.

Sample Code

/*
 * Compiler options needed: /Zi /Od /f-
 */ 

#include <iostream.h>
typedef enum
{
   T1
} TENUM;

class TEST
{
public:
   TEST();
   TENUM linkstate:8;
};

TEST::TEST()
{
   linkstate = T1;
}

TEST *port;
void main(void)
{
   port = new TEST;
   // NOTE: Must refer to linkstate for CXX0033 error to occur.
   port->linkstate;
   delete port;
}
                


Additional query words: 4.00 4.10

Keywords: kb16bitonly KB102367