This version is probably as close to as minimal a source file that can be
that causes error c1026:
//-----------------------------
#pragma once
//
// NOTE: At bottom are two source lines for m_XXX, and m_YYY. if you
comment them both
// out this will compile. If you un-comment one you get first level error,
un-comment
// both you get a second level error (you'll see).
//
// WORKAROUND: Change enough stack semantic members to pointers.
// [courtesy of Vince Yuan]
//
ref class My_Class_A
{
public:
My_Class_A() {}
~My_Class_A() {}
} ;
ref class My_Class_B
{
public:
My_Class_B() {}
~My_Class_B() {}
My_Class_A m_Root ;
My_Class_A m_Inunt ;
My_Class_A m_0_Is ;
My_Class_A m_1_Is ;
My_Class_A m_2_Is ;
My_Class_A m_L_NT ;
My_Class_A m_L_NP ;
My_Class_A m_L_AD ;
My_Class_A m_L_O ;
My_Class_A m_3_Is ;
My_Class_A m_N_Is ;
My_Class_A m_Ount ;
My_Class_A m_0_Os ;
My_Class_A m_1_Os ;
My_Class_A m_2_Os ;
My_Class_A m_3_Os ;
My_Class_A m_N_Os ;
My_Class_A m_Loc ;
My_Class_A m_Ariic ;
My_Class_A m_y ;
My_Class_A m_pason ;
My_Class_A m_stt ;
My_Class_A m_veion ;
My_Class_A m_utode ;
My_Class_A m_puNode ;
My_Class_A m_Ma ;
My_Class_A m_Vaable ;
My_Class_A m_Spial ;
My_Class_A m_L_NND ;
My_Class_A m_L_NR ;
My_Class_A m_L_EU ;
My_Class_A m_C_int ;
My_Class_A m_C_long ;
My_Class_A m_C_float ;
My_Class_A m_C_double ;
My_Class_A m_C_ZO_float ;
My_Class_A m_C_ZO_double ;
My_Class_A m_C_ZO_char ;
My_Class_A m_C_ZO_string ;
My_Class_A m_L_NT_EQU ;
My_Class_A m_L_LFT ;
My_Class_A m_L_RGHT ;
My_Class_A m_L_NT_LEFT ;
My_Class_A m_L_NT_RHT ;
My_Class_A m_L_TUE ;
My_Class_A m_L_FLSE ;
My_Class_A m_L_IPIES ;
My_Class_A m_L_NT_IIS ;
My_Class_A m_L_IPED_BY ;
My_Class_A m_L_NT_IMED_BY ;
My_Class_A m_C_bool ;
My_Class_A m_C_bool_TRUE ;
My_Class_A m_C_bool_FALSE ;
My_Class_A m_C_OE ;
My_Class_A m_C_OE_int ;
My_Class_A m_O_long ;
My_Class_A m_O_float ;
My_Class_A m_O_double ;
My_Class_A m_O_char ;
My_Class_A m_O_string ;
My_Class_A m_O_uni ;
My_Class_A m_C_OE_long ;
My_Class_A m_C_OE_float ;
My_Class_A m_C_OE_double ;
My_Class_A m_C_OE_char ;
My_Class_A m_C_OE_string ;
My_Class_A m_O_bool ;
My_Class_A m_O_int ;
My_Class_A m_C_char ;
My_Class_A m_C_string ;
My_Class_A m_C_PI ;
My_Class_A m_C_ZO ;
My_Class_A m_C_ZO_int ;
My_Class_A m_C_ZO_long ;
My_Class_A m_Sp_DATE ;
My_Class_A m_Sp_TIME ;
My_Class_A m__DD ;
My_Class_A m__DD_int ;
My_Class_A m__DD_long ;
My_Class_A m__DD_float ;
My_Class_A m__ULT_float ;
My_Class_A m__ES_TN_double ;
My_Class_A m__ES_OR_ELS ;
My_Class_A m__ES_OR_ELS_int ;
My_Class_A m__ULT_long ;
My_Class_A m__ES_OR_ELS_float ;
My_Class_A m__ES_OR_ELS_double ;
My_Class_A m__RE_TN ;
My_Class_A m__RE_TN_int ;
My_Class_A m__ULT_double ;
My_Class_A m__ES_TN ;
My_Class_A m__ES_TN_int ;
My_Class_A m__ES_TN_long ;
My_Class_A m__UB_int ;
My_Class_A m__RE_TN_float ;
My_Class_A m__UAS_int ;
My_Class_A m__UAS_long ;
My_Class_A m__UAS_float ;
My_Class_A m__ES_TN_float ;
My_Class_A m__RE_TN_long ;
My_Class_A m__UAS_double ;
My_Class_A m__OT_ELS ;
My_Class_A m__OT_ELS_int ;
My_Class_A m__OT_ELS_long ;
My_Class_A m__OT_ELS_float ;
My_Class_A m__RE_TN_double ;
My_Class_A m__RE_OR_EALS ;
My_Class_A m__RE_OR_EALS_int ;
My_Class_A m__ES_OR_ELS_long ;
My_Class_A m__DD_double ;
My_Class_A m__DD_string ;
My_Class_A m__UB ;
My_Class_A m__UB_long ;
My_Class_A m__UB_float ;
My_Class_A m__UB_double ;
My_Class_A m__ULT ;
My_Class_A m__ULT_int ;
My_Class_A m__RE_OR_EALS_long ;
My_Class_A m__RE_OR_EALS_float ;
My_Class_A m__RE_OR_EALS_double ;
My_Class_A m__UAS ;
My_Class_A m__OT_ELS_double ;
My_Class_A m__IV ;
My_Class_A m__Izas ;
My_Class_A m_XXX ; /// add one to cause first level problem
****************************
My_Class_A m_YYY ; /// add both to cause second level problem
****************************
} ;
//----------------------------------------------
//----------------------------------------------
Peter Oliphant said:
Hi Vince,
However, you present a way I might be able to keep working. I could
change my members to pointers, and if that allows it to compile, then I
can keep working! So thanks again!
[==P==]
Vince Yuan said:
Hi Perteroid,
I changed
OAP_Branch m_Root ;
to
OAP_Branch^ m_Root ;
Compiler accecpted your code.
And another way is to change
ref class OAP_Branch
to
value class OAP_Branch
Hope this helps.