Casting from non-const to const (C2440)

  • Thread starter Thread starter RalphTheExpert
  • Start date Start date
R

RalphTheExpert

Why am I getting the following C2440 error?


public __gc
class X
{
String* Y[];

X(); // Construct Y

public:
const String*
get_Y()
__gc[]
{
return Y; // C2440 error
}

};



I'm guessing it has something to do with String's copy constructor ...
but it surely seems odd to me.

Ralph
 
I beleive __gc syntax doesn't support 'const' as a directive might me the
problem...

[==P==]
 
Back
Top