www.digitalmars.com         C & C++   DMDScript  

c++.wxwindows - New errors in 8.39 with wxCVS head

reply "W這dzimierz Skiba" <abx abx.art.pl> writes:
8.39 release introduced some new errors into building of CVS head. Each of 
them is related to unrolling of WX_DEFINE_USER_EXPORTED_ARRAY_* in 
..\..\include\wx/dynarray.h.

I have truncated this problem to as small as possible example and tested it 
additionaly with online machine at Comeau. Below is result of my investigation.
With 
simple:
  dmc dummy.cpp
as well as in full wxWindows-like command line:
  dmc -mn -c -odmc_msw\monolib_dummy.obj -o -D__WXMSW__ -I..\..\include 
      -I..\..\lib\dmc_lib\msw -w-  -I..\..\src\tiff -I..\..\src\jpeg
-I..\..\src\png 
      -I..\..\src\zlib  -I..\..\src\regex -I..\..\src\expat\lib -DwxUSE_BASE=1
-Ar 
      -Ae    ..\..\src\msw\dummy.cpp 

it gives the same errors:
  typedef wxBaseArrayShort::iterator biterator;
                                   ^
dummy.cpp(26) : Error: member 'wxBaseArrayShort::iterator' of class 
'wxBaseArrayShort' is not accessible
  typedef wxBaseArrayShort::const_iterator bconst_iterator;
                                         ^
dummy.cpp(27) : Error: member 'wxBaseArrayShort::const_iterator' of class 
'wxBaseArrayShort' is not accessible
  typedef wxBaseArrayShort::value_type bvalue_type;
                                     ^
dummy.cpp(28) : Error: member 'wxBaseArrayShort::value_type' of class 
'wxBaseArrayShort' is not accessible
  typedef wxBaseArrayShort::const_reference bconst_reference;
                                          ^
dummy.cpp(29) : Error: member 'wxBaseArrayShort::const_reference' of class 
'wxBaseArrayShort' is not accessible
  typedef wxBaseArrayShort::difference_type difference_type;
                                          ^
dummy.cpp(38) : Error: member 'wxBaseArrayShort::difference_type' of class 
'wxBaseArrayShort' is not accessible
Fatal error: too many errors


And finally minimal dummy.cpp code I got:




typedef short _wxArraywxBaseArrayShort;

class wxBaseArrayShort
{
public:
  wxBaseArrayShort();
  ~wxBaseArrayShort();
	
protected:
  typedef _wxArraywxBaseArrayShort value_type;
  typedef value_type* iterator;
  typedef const value_type* const_iterator;
  typedef value_type& reference;
  typedef const value_type& const_reference;
  typedef int difference_type;
};

typedef short _wxArraywxArrayShort;

class wxArrayShort : public wxBaseArrayShort
{
public:
  wxArrayShort();
  ~wxArrayShort();
private:
  typedef wxBaseArrayShort::iterator biterator;
  typedef wxBaseArrayShort::const_iterator bconst_iterator;
  typedef wxBaseArrayShort::value_type bvalue_type;
  typedef wxBaseArrayShort::const_reference bconst_reference;
public:
  typedef _wxArraywxArrayShort value_type;
  typedef value_type* pointer;
  typedef const value_type* const_pointer;
  typedef value_type* iterator;
  typedef const value_type* const_iterator;
  typedef value_type& reference;
  typedef const value_type& const_reference;
  typedef wxBaseArrayShort::difference_type difference_type;
};





ABX
Feb 17 2004
parent reply "Walter" <walter digitalmars.com> writes:
You can work around the problem by changing it from 'protected' to 'public'.
Meanwhile, I'll see about fixing it. -Walter

"W這dzimierz Skiba" <abx abx.art.pl> wrote in message
news:c0sjkg$2lfh$1 digitaldaemon.com...
 8.39 release introduced some new errors into building of CVS head. Each of
 them is related to unrolling of WX_DEFINE_USER_EXPORTED_ARRAY_* in
 ..\..\include\wx/dynarray.h.

 I have truncated this problem to as small as possible example and tested
it
 additionaly with online machine at Comeau. Below is result of my
investigation. With
 simple:
   dmc dummy.cpp
 as well as in full wxWindows-like command line:
   dmc -mn -c -odmc_msw\monolib_dummy.obj -o -D__WXMSW__ -I..\..\include
       -I..\..\lib\dmc_lib\msw -w-  -I..\..\src\tiff -I..\..\src\jpeg -I..\
..\src\png
       -I..\..\src\zlib  -I..\..\src\regex -I..\..\src\expat\lib -DwxUSE_BA
SE=1 -Ar
       -Ae    ..\..\src\msw\dummy.cpp

 it gives the same errors:
   typedef wxBaseArrayShort::iterator biterator;
                                    ^
 dummy.cpp(26) : Error: member 'wxBaseArrayShort::iterator' of class
 'wxBaseArrayShort' is not accessible
   typedef wxBaseArrayShort::const_iterator bconst_iterator;
                                          ^
 dummy.cpp(27) : Error: member 'wxBaseArrayShort::const_iterator' of class
 'wxBaseArrayShort' is not accessible
   typedef wxBaseArrayShort::value_type bvalue_type;
                                      ^
 dummy.cpp(28) : Error: member 'wxBaseArrayShort::value_type' of class
 'wxBaseArrayShort' is not accessible
   typedef wxBaseArrayShort::const_reference bconst_reference;
                                           ^
 dummy.cpp(29) : Error: member 'wxBaseArrayShort::const_reference' of class
 'wxBaseArrayShort' is not accessible
   typedef wxBaseArrayShort::difference_type difference_type;
                                           ^
 dummy.cpp(38) : Error: member 'wxBaseArrayShort::difference_type' of class
 'wxBaseArrayShort' is not accessible
 Fatal error: too many errors


 And finally minimal dummy.cpp code I got:




 typedef short _wxArraywxBaseArrayShort;

 class wxBaseArrayShort
 {
 public:
   wxBaseArrayShort();
   ~wxBaseArrayShort();

 protected:
   typedef _wxArraywxBaseArrayShort value_type;
   typedef value_type* iterator;
   typedef const value_type* const_iterator;
   typedef value_type& reference;
   typedef const value_type& const_reference;
   typedef int difference_type;
 };

 typedef short _wxArraywxArrayShort;

 class wxArrayShort : public wxBaseArrayShort
 {
 public:
   wxArrayShort();
   ~wxArrayShort();
 private:
   typedef wxBaseArrayShort::iterator biterator;
   typedef wxBaseArrayShort::const_iterator bconst_iterator;
   typedef wxBaseArrayShort::value_type bvalue_type;
   typedef wxBaseArrayShort::const_reference bconst_reference;
 public:
   typedef _wxArraywxArrayShort value_type;
   typedef value_type* pointer;
   typedef const value_type* const_pointer;
   typedef value_type* iterator;
   typedef const value_type* const_iterator;
   typedef value_type& reference;
   typedef const value_type& const_reference;
   typedef wxBaseArrayShort::difference_type difference_type;
 };





 ABX
Feb 17 2004
parent "W這dzimierz Skiba" <abx abx.art.pl> writes:
"Walter" <walter digitalmars.com> wrote in
news:c0to3o$1f2g$2 digitaldaemon.com: 

 You can work around the problem by changing it from 'protected' to
 'public'. Meanwhile, I'll see about fixing it. -Walter
Thanks, new beta compiles fine that code. I can't test resulting exacutables because of the problem mentioned in other thread by somebody. ABX
Feb 18 2004